Error reporting strange behavior

Kristijan Škrlin posted 9 months ago

Laravel Version: 5.4.36 PHP Version: 7.1.0 Database Driver & Version: MySQL 5.7.18

I have 2 different projects with the same configurations. Laravel framework version is the same and php version is the same. PHP error_reporting is set to -1 on both projects. If I try to echo undefined variable {{ $foo }}, in one project I get null, on other project I get Whoops page: Undefined variable: foo. The proper way would be to check if variable exists or is set, but why I am getting null on one project, instead of undefined variable notice? What can be causing this kind of behavior?

When I use undefined function, it throws Whoops on both projects, i.e. {{ dump(_check($foo)) }}

Sign in to participate in this thread!

We'd like to thank these amazing companies for supporting us