perf: 隐藏无聊天内容的对话

This commit is contained in:
kuaifan 2022-01-23 14:51:32 +08:00
parent fcf7fb4b9f
commit 004bf36dc1

View File

@ -126,10 +126,13 @@ export default {
if (dialogActive == '' && dialogKey == '') {
return this.cacheDialogs.filter(({name}) => name !== undefined);
}
return this.cacheDialogs.filter(({name, type, group_type, last_msg}) => {
return this.cacheDialogs.filter(({name, type, group_type, last_msg, last_at}) => {
if (name === undefined) {
return false;
}
if (!last_at) {
return false;
}
if (dialogActive) {
switch (dialogActive) {
case 'project':