re-factor / cleanup
This commit is contained in:
@@ -862,8 +862,7 @@ async function getUserOptions() {
|
||||
"logItem",
|
||||
"Initialize::() fetch useroptions -> error" + error
|
||||
);
|
||||
// throw new Error(error);
|
||||
throw new Error(window.$gz.errorHandler.errorToString(res));
|
||||
throw new Error(window.$gz.errorHandler.errorToString(error));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -871,6 +870,7 @@ async function getUserOptions() {
|
||||
// Initialize the app
|
||||
// on change of authentication status
|
||||
export default function initialize() {
|
||||
// eslint-disable-next-line no-async-promise-executor
|
||||
return new Promise(async function(resolve, reject) {
|
||||
if (!window.$gz.store.state.authenticated) {
|
||||
throw new Error("initialize: Error, called but user not authenticated!");
|
||||
|
||||
Reference in New Issue
Block a user