[interchange-cvs] interchange - heins modified code/SystemTag/catch.coretag
interchange-core@interchange.redhat.com
interchange-core@interchange.redhat.com
Fri Jun 28 15:57:00 2002
User: heins
Date: 2002-06-28 19:56:43 GMT
Modified: code/SystemTag catch.coretag
Log:
* More changes to [catch] [/catch]
-- [catch error-set="Route failed"] The error [/catch] allows setting
of IC errors for display on checkout (or wherever). Will provide
foundation catalog support in log_transaction.
-- hide=1 option allows return of nothing to body while still setting
error value.
Revision Changes Path
1.3 +5 -0 interchange/code/SystemTag/catch.coretag
rev 1.3, prev_rev 1.2
Index: catch.coretag
===================================================================
RCS file: /anon_cvs/repository/interchange/code/SystemTag/catch.coretag,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- catch.coretag 28 Jun 2002 19:34:29 -0000 1.2
+++ catch.coretag 28 Jun 2002 19:56:43 -0000 1.3
@@ -58,6 +58,11 @@
$body =~ s/\s+$//;
$body =~ s/^\s+//;
+
+ if($opt->{error_set}) {
+ set_error($body, $opt->{error_set});
+ }
+ return '' if $opt->{hide};
return $body;
}
EOR