diff --git a/app/Http/Controllers/Admin/SettingsController.php b/app/Http/Controllers/Admin/SettingsController.php index fc11b0734d4..2fc962aec9f 100644 --- a/app/Http/Controllers/Admin/SettingsController.php +++ b/app/Http/Controllers/Admin/SettingsController.php @@ -20,6 +20,7 @@ class SettingsController extends Controller public function getAll(GetAllConfigsRequest $request): ConfigCollectionResource { $editable_configs = Configs::query() + ->when(config('features.hide-lychee-SE', false) === true, fn ($q) => $q->where('cat', '!=', 'lychee SE')) ->when(!$request->is_se() && !Configs::getValueAsBool('enable_se_preview'), fn ($q) => $q->where('level', '=', 0)) ->orderBy('cat', 'asc')->get(); diff --git a/config/features.php b/config/features.php index b6a27b551bb..8165634ece6 100644 --- a/config/features.php +++ b/config/features.php @@ -69,4 +69,11 @@ | Put images on AWS instead of locally to save space. */ 'use-s3' => (env('AWS_ACCESS_KEY_ID', '') !== '') && (bool) env('S3_ENABLED', false), + + /* + |-------------------------------------------------------------------------- + | Hide Lychee SE from config to allow for easier video + |-------------------------------------------------------------------------- + */ + 'hide-lychee-SE' => (bool) env('HIDE_LYCHEE_SE_CONFIG', false), ]; \ No newline at end of file