forked from vikunja/frontend
chore: use .then instead of await
This commit is contained in:
parent
e08c3a3594
commit
ef69fd28b2
|
@ -80,9 +80,12 @@ import CaldavTokenModel from '@/models/caldavToken'
|
||||||
|
|
||||||
const service = new CaldavTokenService()
|
const service = new CaldavTokenService()
|
||||||
|
|
||||||
async function useTokens(): ref<CaldavTokenModel[]> {
|
function useTokens(): ref<CaldavTokenModel[]> {
|
||||||
const tokens = ref<CaldavTokenModel[]>([])
|
const tokens = ref<CaldavTokenModel[]>([])
|
||||||
tokens.value = await service.getAll()
|
service.getAll()
|
||||||
|
.then((t: CaldavTokenModel[]) => {
|
||||||
|
tokens.value = t
|
||||||
|
})
|
||||||
return tokens
|
return tokens
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user