Ticket #119 (closed defect: fixed)
Requests to /page/blah cause an exception
| Reported by: | michaeltwofish | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 0.4 |
| Component: | Habari Core Software | Version: | SVN |
| Keywords: | Cc: |
Description
Requests to /page/{page} are used for pagination, but an exception is thrown if {page} is not an integer. Below is the exception (with DEBUG set to true).
If Habari's error handling is not enabled (by commenting out Error::handle_errors(); in index.php) the 404 template is displayed correctly.
Uncaught Exception: Exception: Trying to get property of non-object
#0 in system/classes/userthemehandler.php:36:
Error::error_handler(
8, 'Trying to get property of non-object', '/Applications/MAMP/htdocs/habari/system/classes/userthemehandler.php', 36, array (
'action' => 'display_404', 'request' => stdClass::set_state(array( )), 'rule' => RewriteRule::set_state(array(
'entire_match' => NULL, 'named_arg_values' =>
array ( ),
'm_named_args' => NULL, 'fields' =>
array (
'rule_id' => 0, 'name' => 'atompub_servicedocument', 'parse_regex' => '%atom$%i', 'build_str' => 'atom', 'handler' => 'AtomHandler', 'action' => 'introspection', 'priority' => 1, 'is_active' => 1, 'rule_class' => 0, 'description' => 'Atom introspection',
),
'newfields' =>
array ( ),
'unsetfields' =>
array (
'rule_id' =&...)
#1 in system/classes/controller.php:180:
UserThemeHandler->act(
'display_404'
)
#2 in index.php:186:
Controller::dispatch_request()
