Skip to content

Commit

Permalink
Merge pull request silverstripe#181 from creative-commoners/pulls/5.2…
Browse files Browse the repository at this point in the history
…/remove-self

ENH Use class name instead of self
  • Loading branch information
GuySartorelli authored Jun 17, 2024
2 parents f9f8cd6 + b34ad95 commit 35c3cb5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/EnablerExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ public function beforeCallActionHandler()
$config = Config::inst();
$action = $this->getOwner()->getAction();
$allowedActions = $config->get(Security::class, 'allowed_actions');
$excludedActions = $config->get(self::class, 'excluded_actions');
$excludedActions = $config->get(EnablerExtension::class, 'excluded_actions');
$themeActions = array_diff($allowedActions ?? [], $excludedActions);
if (in_array($action, $themeActions ?? [])) {
SSViewer::set_themes($config->get(self::class, 'login_themes'));
SSViewer::set_themes($config->get(EnablerExtension::class, 'login_themes'));
}
$this->defaultPageClass = $config->get(Security::class, 'page_class');
Config::modify()->remove(Security::class, 'page_class');
Expand Down

0 comments on commit 35c3cb5

Please sign in to comment.