mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
config is not defined yet on load
This commit is contained in:
@@ -204,12 +204,20 @@ export default {
|
||||
return Object.fromEntries(enabledPreferences);
|
||||
},
|
||||
hasLogout() {
|
||||
const Galaxy = getGalaxyInstance();
|
||||
return !!Galaxy.session_csrf_token && !this.config.single_user;
|
||||
if (this.isConfigLoaded) {
|
||||
const Galaxy = getGalaxyInstance();
|
||||
return !!Galaxy.session_csrf_token && !this.config.single_user;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
hasThemes() {
|
||||
const themes = Object.keys(this.config.themes);
|
||||
return themes?.length > 1 ?? false;
|
||||
if (this.isConfigLoaded) {
|
||||
const themes = Object.keys(this.config.themes);
|
||||
return themes?.length > 1 ?? false;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
userPermissionsUrl() {
|
||||
return withPrefix("/user/permissions");
|
||||
|
||||
Reference in New Issue
Block a user