jenssegers / laravel-rollbar

Rollbar error monitoring integration for Laravel projects
328 stars 98 forks source link

Ignore NotFoundHttpException #5

Closed Znarkus closed 9 years ago

Znarkus commented 9 years ago

Hi! Is there any way to ignore NotFoundHttpException?

potsky commented 9 years ago

Yes, instead of calling Log::error(), use this :

if ( ! ends_with( get_class( $e ) , 'NotFoundHttpException' ) ) {
    Log::error()
}
jenssegers commented 9 years ago

Even better would be:

if ( ! $e instanceof \Symfony\Component\HttpKernel\Exception\NotFoundHttpException)