fix: 修复头像出现D的情况

This commit is contained in:
Pang 2023-12-17 16:18:28 +08:00
parent 971167cad3
commit 37ccf4dacb

View File

@ -36,9 +36,13 @@ export default {
mounted() {
this.getData();
//
this.subscribe = Store.subscribe('userActive', ({data}) => {
this.subscribe = Store.subscribe('userActive', ({type, data}) => {
if (data.userid == this.userid) {
this.setUser(data)
if (type === 'line') {
this.user && this.$set(this.user, 'online', data.online);
} else {
this.setUser(data)
}
}
});
this.$store.state.userAvatar[this._uid] = this.$props;