From cd874c5f58eb8db0e5f63b7c073f3bc304e4f2bb Mon Sep 17 00:00:00 2001 From: Miguel Nogueira Date: Mon, 31 Aug 2020 18:36:38 +0100 Subject: [PATCH] Settings auth checks --- app/Http/Controllers/OptionsController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/OptionsController.php b/app/Http/Controllers/OptionsController.php index 5728862..436dbab 100644 --- a/app/Http/Controllers/OptionsController.php +++ b/app/Http/Controllers/OptionsController.php @@ -27,7 +27,7 @@ class OptionsController extends Controller public function saveSettings(Request $request) { - if (Auth::user()->hasPermission('admin.settings.edit')) + if (Auth::user()->can('admin.settings.edit')) { foreach($request->all() as $optionName => $option) {