Index: openacs-4/packages/xowiki/tcl/package-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/package-procs.tcl,v diff -u -r1.279.2.17 -r1.279.2.18 --- openacs-4/packages/xowiki/tcl/package-procs.tcl 9 Dec 2014 09:34:11 -0000 1.279.2.17 +++ openacs-4/packages/xowiki/tcl/package-procs.tcl 10 Dec 2014 19:12:46 -0000 1.279.2.18 @@ -801,11 +801,10 @@ return [my error_msg "Method '$method' is not defined for this object"] } else { #my msg "--invoke [my set object] id=$page_or_package method=$method ([my id] batch_mode $batch_mode)" - set errorMsg "" if {$batch_mode} {[my id] set __batch_mode 1} - catch { set r [my call $page_or_package $method ""]} errorMsg + set err [catch { set r [my call $page_or_package $method ""]} errorMsg] if {$batch_mode} {[my id] unset __batch_mode} - if {$errorMsg ne ""} { + if {$err} { return [my error_msg -status_code 404 \ -template_file $error_template \ [ns_quotehtml $errorMsg]]