Skip to content

Commit

Permalink
Ensure themes are applied for Security::permissionFailure() calls
Browse files Browse the repository at this point in the history
  • Loading branch information
dizzystuff committed Jul 23, 2024
1 parent 75ec2e0 commit 433d69b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/EnablerExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@ public function afterCallActionHandler()
Config::inst()->set(Security::class, 'page_class', $this->defaultPageClass);
}

public function onBeforeSecurityLogin()
{
SSViewer::set_themes(Config::inst()->get(EnablerExtension::class, 'login_themes'));
Config::modify()->remove(Security::class, 'page_class');
}

/**
* Returns an RFC1766 compliant locale string, e.g. 'fr-CA'.
*
Expand Down

0 comments on commit 433d69b

Please sign in to comment.