Skip to content

Commit

Permalink
require admin for any settings action
Browse files Browse the repository at this point in the history
  • Loading branch information
i-just committed Dec 9, 2024
1 parent 3a9b3fb commit ddb9d31
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/controllers/SettingsController.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,17 @@
*/
class SettingsController extends Controller
{

/**
* @inheritdoc
*/
public function beforeAction($action): bool
{
$this->requireAdmin();

return parent::beforeAction($action);
}

/**
* Display a form to allow an administrator to update plugin's API settings.
*
Expand Down

0 comments on commit ddb9d31

Please sign in to comment.