jenssegers / laravel-rollbar

Rollbar error monitoring integration for Laravel projects
329 stars 99 forks source link

Detect Environment #47

Closed mydnic closed 8 years ago

mydnic commented 8 years ago

Hello, Is it possible to add something in the configuration file that allows to only send errors to rollbar on certain environment ? Like, I don't necessary need to log errors to rollbar when I am working in local. Only in Staging and production for example.

Before I was using a simple if (env('APP_ENV') != 'local') to trigger the rollbar report, but since Laravel 5.2 it seems that doesn't work anymore :(

Many thanks

pedrommone commented 8 years ago

I guess its related to #43

mydnic commented 8 years ago

seems to work with the solution provided in #43 ! the return just has to be in the if condition as well thanks a lot