Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

is_a is not supported #1152

Open
i582 opened this issue Sep 9, 2021 · 0 comments
Open

is_a is not supported #1152

i582 opened this issue Sep 9, 2021 · 0 comments
Labels
bug Something isn't working

Comments

@i582
Copy link
Contributor

i582 commented Sep 9, 2021

PHP Version: 7.4 and 8.0

OS: macOS

The minimal code in which the bug appears:

if (is_a($parent, 'Kirby\Cms\File') === true && $file = $parent->page()->file($path)) { ... }

Actual Behavior:

undefinedMethod: Call to undefined method {\Kirby\Cms\Model|null}->page()

Expected Behavior:

No error.

@i582 i582 added the bug Something isn't working label Sep 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant