pull/3284/merge
花裤衩 2024-11-28 00:28:54 +00:00 committed by GitHub
commit 55374aa6d9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -51,14 +51,14 @@ const actions = {
const { data } = response
if (!data) {
reject('Verification failed, please Login again.')
return reject('Verification failed, please Login again.')
}
const { roles, name, avatar, introduction } = data
// roles must be a non-empty array
if (!roles || roles.length <= 0) {
reject('getInfo: roles must be a non-null array!')
return reject('getInfo: roles must be a non-null array!')
}
commit('SET_ROLES', roles)