فهرست منبع

Update Exception handler

Daniel Supernault 3 سال پیش
والد
کامیت
c481e473d8
1فایلهای تغییر یافته به همراه12 افزوده شده و 0 حذف شده
  1. 12 0
      app/Exceptions/Handler.php

+ 12 - 0
app/Exceptions/Handler.php

@@ -41,6 +41,18 @@ class Handler extends ExceptionHandler
 		parent::report($exception);
 	}
 
+	/**
+	* Register the exception handling callbacks for the application.
+	*
+	* @return void
+	*/
+	public function register()
+	{
+		$this->reportable(function (\BadMethodCallException $e) {
+			return app()->environment() !== 'production';
+		});
+	}
+
 	/**
 	 * Render an exception into an HTTP response.
 	 *