Merge pull request #9434 from mattclegg/bugfix--silverstripe-admin--requirements

[BUGFIX] silverstripe/admin is not required to be installed
This commit is contained in:
Robbie Averill 2020-03-16 09:48:39 -07:00 committed by GitHub
commit b6512edec8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -39,9 +39,11 @@ class CMSSecurity extends Security
// Assign default cms theme and replace user-specified themes // Assign default cms theme and replace user-specified themes
SSViewer::set_themes(LeftAndMain::config()->uninherited('admin_themes')); SSViewer::set_themes(LeftAndMain::config()->uninherited('admin_themes'));
// Core styles / vendor scripts if (ModuleLoader::getModule('silverstripe/admin')) {
Requirements::javascript('silverstripe/admin: client/dist/js/vendor.js'); // Core styles / vendor scripts
Requirements::css('silverstripe/admin: client/dist/styles/bundle.css'); Requirements::javascript('silverstripe/admin: client/dist/js/vendor.js');
Requirements::css('silverstripe/admin: client/dist/styles/bundle.css');
}
} }
public function login($request = null, $service = Authenticator::CMS_LOGIN) public function login($request = null, $service = Authenticator::CMS_LOGIN)