Skip to content
This repository was archived by the owner on Jan 12, 2023. It is now read-only.

Commit d2442b5

Browse files
authored
check instance first
1 parent 2bdce2f commit d2442b5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/InertiaStatamic.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ public function handle(Request $request, Closure $next)
2525
{
2626
$page = app(FrontendController::class)->index($request);
2727

28-
if ($page->template() === 'app' && ($page instanceof Page || $page instanceof Entry)) {
28+
if (($page instanceof Page || $page instanceof Entry) && $page->template() === 'app') {
2929
return Inertia::render(
3030
$this->buildComponentPath($page),
3131
$this->buildProps($page)

0 commit comments

Comments
 (0)