depend on URI::Escape version which escapes quotes
[freeside.git] / FS / FS / Mason.pm
index 2a0908a..e26a4b7 100644 (file)
@@ -69,7 +69,7 @@ if ( -e $addl_handler_use_file ) {
   Lingua::EN::Inflect::classical names=>0; #Categorys
   use Tie::IxHash;
   use URI;
-  use URI::Escape;
+  use URI::Escape 3.31;
   use HTML::Entities;
   use HTML::TreeBuilder;
   use HTML::TableExtract qw(tree);
@@ -514,28 +514,7 @@ sub mason_interps {
     RT::LoadConfig();
   }
 
-  # A hook supporting strange legacy ways people (well, SG) have added stuff on
-
-  my @addl_comp_root = ();
-  my $addl_comp_root_file = '%%%FREESIDE_CONF%%%/addl_comp_root.pl';
-  if ( -e $addl_comp_root_file ) {
-    warn "reading $addl_comp_root_file\n";
-    my $text = slurp( $addl_comp_root_file );
-    my @addl = eval $text;
-    if ( @addl && ! $@ ) {
-      @addl_comp_root = @addl;
-    } elsif ($@) {
-      warn "error parsing $addl_comp_root_file: $@\n";
-    }
-  }
-
-  my $fs_comp_root =
-    scalar(@addl_comp_root)
-      ? [
-          [ 'freeside'=>'%%%FREESIDE_DOCUMENT_ROOT%%%' ],
-          @addl_comp_root,
-        ]
-      : '%%%FREESIDE_DOCUMENT_ROOT%%%';
+  my $fs_comp_root = '%%%FREESIDE_DOCUMENT_ROOT%%%';
 
   my %interp = (
     request_class        => $request_class,
@@ -588,7 +567,7 @@ sub mason_interps {
                     },
     compiler     => HTML::Mason::Compiler::ToObject->new(
                       default_escape_flags => 'h',
-                      allow_globals        => [qw(%session)],
+                      allow_globals        => [qw(%session $DECODED_ARGS)],
                     ),
   );