mirror of
https://github.com/HuLaSpark/HuLa.git
synced 2026-10-24 11:53:36 +08:00
fix(common): 🐛 logout notify when other login
This commit is contained in:
@@ -119,7 +119,8 @@ export const useLogin = () => {
|
||||
const userDetail: any = await getUserDetail()
|
||||
userStatusStore.stateId = userDetail.userStateId
|
||||
const account = {
|
||||
...userDetail
|
||||
...userDetail,
|
||||
client: isDesktop() ? 'PC' : 'MOBILE'
|
||||
}
|
||||
userStore.userInfo = account
|
||||
loginHistoriesStore.addLoginHistory(account)
|
||||
|
||||
@@ -35,6 +35,7 @@ export class AvatarUtils {
|
||||
public static getAvatarUrl(avatar: string): string {
|
||||
const DEFAULT = '/logoD.png'
|
||||
|
||||
if (!avatar) return DEFAULT
|
||||
const rawAvatar = avatar.trim()
|
||||
if (AvatarUtils.isDefaultAvatar(rawAvatar)) {
|
||||
return `/avatar/${rawAvatar}.webp`
|
||||
|
||||
Reference in New Issue
Block a user