modernize error reporting for the shop's cart target
authorTony Cook <tony@develop-help.com>
Fri, 17 Apr 2015 01:30:07 +0000 (11:30 +1000)
committerTony Cook <tony@develop-help.com>
Fri, 24 Apr 2015 05:52:57 +0000 (15:52 +1000)
site/cgi-bin/modules/BSE/UI/Shop.pm

index 6a3f312..7b59bd6 100644 (file)
@@ -18,7 +18,7 @@ use BSE::Countries qw(bse_country_code);
 use BSE::Util::Secure qw(make_secret);
 use BSE::Template;
 
-our $VERSION = "1.047";
+our $VERSION = "1.048";
 
 =head1 NAME
 
@@ -111,10 +111,7 @@ sub req_cart {
   # my %custom_state = %{$req->session->{custom}};
 
   # $cust_class->enter_cart(\@cart, \@cart_prods, \%custom_state, $req->cfg);
-  $msg = '' unless defined $msg;
-  $msg = escape_html($msg);
-
-  $msg ||= $req->message;
+  $msg = $req->message($msg);
   
   my %acts;
   %acts =