Corrected Loading error
This commit is contained in:
@@ -217,8 +217,12 @@ export const useDataStore = defineStore('data', () => {
|
|||||||
])
|
])
|
||||||
|
|
||||||
async function initializeData () {
|
async function initializeData () {
|
||||||
await fetchProfiles()
|
//console.log(user.value.id)
|
||||||
currentTenant.value = profiles.value.find(i => i.id === user.value.id).tenants[0].id
|
let profile = (await supabase.from("profiles").select().eq("id",user.value.id).single()).data
|
||||||
|
|
||||||
|
//console.log(profile)
|
||||||
|
|
||||||
|
currentTenant.value = profile.tenant//profiles.value.find(i => i.id === user.value.id).tenants[0].id
|
||||||
|
|
||||||
await fetchData()
|
await fetchData()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user