feat: bump to latest vue 3.4.19 (#2607)
Co-authored-by: patak <matias.capeletto@gmail.com>
This commit is contained in:
parent
81ef8ff9aa
commit
36004a7eba
40 changed files with 601 additions and 451 deletions
|
@ -91,10 +91,6 @@ export async function fetchAccountByHandle(acct: string): Promise<mastodon.v1.Ac
|
|||
return account
|
||||
}
|
||||
|
||||
export function useAccountByHandle(acct: string) {
|
||||
return useAsyncState(() => fetchAccountByHandle(acct), null).state
|
||||
}
|
||||
|
||||
export function useAccountById(id?: string | null) {
|
||||
return useAsyncState(() => fetchAccountById(id), null).state
|
||||
}
|
||||
|
|
|
@ -362,20 +362,20 @@ export function useUserLocalStorage<T extends object>(key: string, initial: () =
|
|||
// Backward compatibility, respect webDomain in acct
|
||||
// In previous versions, acct was username@server instead of username@webDomain
|
||||
// for example: elk@m.webtoo.ls instead of elk@webtoo.ls
|
||||
// if (!all.value[id]) { // TODO: add back this condition in the future
|
||||
const [username, webDomain] = id.split('@')
|
||||
const server = currentServer.value
|
||||
if (webDomain && server && server !== webDomain) {
|
||||
const oldId = `${username}@${server}`
|
||||
const outdatedSettings = all.value[oldId]
|
||||
if (outdatedSettings) {
|
||||
const newAllValue = { ...all.value, [id]: outdatedSettings }
|
||||
delete newAllValue[oldId]
|
||||
all.value = newAllValue
|
||||
if (!all.value[id]) {
|
||||
const [username, webDomain] = id.split('@')
|
||||
const server = currentServer.value
|
||||
if (webDomain && server && server !== webDomain) {
|
||||
const oldId = `${username}@${server}`
|
||||
const outdatedSettings = all.value[oldId]
|
||||
if (outdatedSettings) {
|
||||
const newAllValue = { ...all.value, [id]: outdatedSettings }
|
||||
delete newAllValue[oldId]
|
||||
all.value = newAllValue
|
||||
}
|
||||
}
|
||||
all.value[id] = Object.assign(initial(), all.value[id] || {})
|
||||
}
|
||||
// }
|
||||
all.value[id] = Object.assign(initial(), all.value[id] || {})
|
||||
return all.value[id]
|
||||
})
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue