http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13995
Olli-Antti Kivilahti <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #40717|0 |1 is obsolete| | --- Comment #10 from Olli-Antti Kivilahti <[email protected]> --- Created attachment 41018 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=41018&action=edit Bug 13995 - Proper Exception handling Koha has issues with propagating errors and exceptions from the business layer to the front-end. Using a more sophisticated system of named Exceptions we can send more formal signals towards the user. Catching different types of Exceptions makes for a more concise handling of errors. Also throwing/catching Exceptions is a industry standard and for a good reason. There is no point for Koha to lurk behind. USAGE: try { Koha::Exception::BadSystemPreference->throw(error => 'Syspref DisplayIconsXSLT is not a valid boolean'); } catch { if (blessed($_) && $_->isa('Koha::Exception::BadSystemPreference')) { print $_->as_string(); warn $_->error, "\n", $_->trace->as_string, "\n"; } else { $_->rethrow(); } } -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
