mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-16 07:57:33 +08:00
code refactor
This commit is contained in:
@@ -264,6 +264,10 @@ function clearUserInfoState(context) {
|
||||
context.commit(CLEAR_USER_INFO);
|
||||
}
|
||||
|
||||
function resetState(context) {
|
||||
context.commit(RESET_STATE);
|
||||
}
|
||||
|
||||
function currentUserNickname(state) {
|
||||
const userInfo = state.currentUserInfo || {};
|
||||
return userInfo.nickname || userInfo.username || null;
|
||||
@@ -282,6 +286,7 @@ export default {
|
||||
getCurrentUserProfile,
|
||||
updateUserProfile,
|
||||
clearUserInfoState,
|
||||
resetState,
|
||||
currentUserNickname,
|
||||
currentUserDefaultCurrency
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user