Make sure that the AssetDiscovery contentHandler was added to all config files.
This commit is contained in:
parent
0967e89c96
commit
1bf24f2682
2 changed files with 24 additions and 0 deletions
|
|
@ -4,6 +4,7 @@
|
|||
- fixed #9677: no output from form helper template variable sticky.form and stick.label
|
||||
- fixed #9738: Gallery Title [TEMPLATE]
|
||||
- fixed #9739: Gallery Delete Album Template [TEMPLATE]
|
||||
- fixed #9737: Upgrade Missed a Config Option
|
||||
|
||||
7.6.11
|
||||
- fixed: Asset Manager can generate URLs that are too long
|
||||
|
|
|
|||
|
|
@ -22,6 +22,7 @@ use Getopt::Long;
|
|||
use WebGUI::Session;
|
||||
use WebGUI::Storage;
|
||||
use WebGUI::Asset;
|
||||
use WebGUI::Utility qw/isIn/;
|
||||
|
||||
|
||||
my $toVersion = '7.6.12';
|
||||
|
|
@ -29,6 +30,7 @@ my $quiet; # this line required
|
|||
|
||||
|
||||
my $session = start(); # this line required
|
||||
addAssetDiscoveryServiceAgain( $session );
|
||||
|
||||
# upgrade functions go here
|
||||
|
||||
|
|
@ -44,6 +46,27 @@ finish($session); # this line required
|
|||
# print "DONE!\n" unless $quiet;
|
||||
#}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
sub addAssetDiscoveryServiceAgain {
|
||||
my $session = shift;
|
||||
print "\tAdding asset discovery service..." unless $quiet;
|
||||
my @handlers = @{ $session->config->get('contentHandlers') };
|
||||
if (isIn( 'WebGUI::Content::AssetDiscovery', @handlers) ) {
|
||||
print "Done.\n" unless $quiet;
|
||||
return;
|
||||
}
|
||||
my @newHandlers = ();
|
||||
foreach my $handler (@handlers) {
|
||||
if ($handler eq 'WebGUI::Content::Operation') {
|
||||
push @newHandlers, 'WebGUI::Content::AssetDiscovery';
|
||||
}
|
||||
push @newHandlers, $handler;
|
||||
}
|
||||
$session->config->set('contentHandlers', \@newHandlers);
|
||||
print "Done.\n" unless $quiet;
|
||||
}
|
||||
|
||||
|
||||
|
||||
# -------------- DO NOT EDIT BELOW THIS LINE --------------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue