WWW::Kontent::Exceptions - Kontent exceptions
WWW::Kontent::error("message", :code(402)); WWW::Kontent::restart(:mode('view'));
WWW::Kontent::Exceptions contains functions and classes used to communicate errors and other conditions within Kontent. As Pugs cannot currently throw full objects, this is currently done with strings.
Communicates a fatal error, such as "page not found", to Kontent. The error message is passed in, and an optional HTTP status code can be specified with the named parameter 'code'.
Tells Kontent to change the specified attributes in the request object and restart its attempt to render the page. This can be used to handle situations such as redirects and changes in the page's mode or format.
To help prevent restart loops, at least one attribute must be changed. If you're really sure you don't need to reset anything, simply pass in
:renderer(undef); the correct renderer will be filled in after the restart.
XXX currently very out of date