3 ms·
Its common for me in PHP land to call die("Error! $e"); when something really bad has happened in a request and I really don't want anything to happen
by jetbalsa 4y ago
Its common for me in PHP land to call die("Error! $e"); when something really bad has happened in a request and I really don't want anything to happen
- akdor1154 4y agoYeah nice, PHP's request scoping is a really good fit for this.
- theluketowers 4y agoThat's not without its drawbacks however, especially when you consider tools like swoole and laravel octane that keep your application in a long running process, so if you use die you actually kill one of the server workers instead of just terminating the execution of the request