Browse Source

fix(nc-gui): actions issues

pull/5307/head
Wing-Kam Wong 2 years ago
parent
commit
60443209e5
  1. 6
      packages/nc-gui/composables/useGlobal/actions.ts

6
packages/nc-gui/composables/useGlobal/actions.ts

@ -1,4 +1,4 @@
import type { Actions, State } from './types'
import type { Actions, AppInfo, State } from './types'
import { message, useNuxtApp } from '#imports'
export function useGlobalActions(state: State): Actions {
@ -48,14 +48,14 @@ export function useGlobalActions(state: State): Actions {
message.error(err.message || t('msg.error.youHaveBeenSignedOut'))
await signOut()
})
.finally(resolve)
.finally(() => resolve)
})
}
const loadAppInfo = async () => {
try {
const nuxtApp = useNuxtApp()
state.appInfo.value = await nuxtApp.$api.utils.appInfo()
state.appInfo.value = (await nuxtApp.$api.utils.appInfo()) as AppInfo
} catch (e) {
console.error(e)
}

Loading…
Cancel
Save