diff --git a/config/prequel.php b/config/prequel.php index 2c16f96..70268e1 100644 --- a/config/prequel.php +++ b/config/prequel.php @@ -14,6 +14,17 @@ */ 'enabled' => env('PREQUEL_ENABLED', true), + + /* + |-------------------------------------------------------------------------- + | Prequel Production Master Switch : boolean + |-------------------------------------------------------------------------- + | + | Manually enable Prequel in production. This setting should not be enabled! + | + */ + + 'production_enabled' => env('PREQUEL_PRODUCTION_ENABLED', false), /* diff --git a/src/Http/Middleware/Authorised.php b/src/Http/Middleware/Authorised.php index 193d45b..ec75caa 100644 --- a/src/Http/Middleware/Authorised.php +++ b/src/Http/Middleware/Authorised.php @@ -90,7 +90,7 @@ private function configurationCheck() { return (object)[ "enabled" => - config("prequel.enabled") && config("app.env") !== "production", + config("prequel.enabled") && (config("app.env") !== "production" || config("prequel.production_enabled")), "detailed" => "Prequel has been disabled.", ]; }