Skip to content

Commit

Permalink
Merge pull request #9 from level-level/NielsdeBlaauw-patch-1
Browse files Browse the repository at this point in the history
Fix unavailable 404 page.
  • Loading branch information
NielsdeBlaauw authored Nov 17, 2023
2 parents 1268d58 + d4ef141 commit 2ac350c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion clarkson-404.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,11 @@ public function add_404_object( $objects ) {

$object_loader = Objects::get_instance();

$page = $object_loader->get_object( $id );
try {
$page = $object_loader->get_object( $id );
} catch ( \Exception $e ) {
return $objects;
}

$objects['objects'] = array( $page );

Expand Down

0 comments on commit 2ac350c

Please sign in to comment.