Fix not receiving messages after deleting all
This commit is contained in:
parent
81d00cbd57
commit
985c7cf870
|
|
@ -28,10 +28,10 @@ export class MessagesStore {
|
|||
}
|
||||
|
||||
private stateOf = (appId: number, create = true) => {
|
||||
if (this.state[appId] || !create) {
|
||||
return this.state[appId] || this.emptyState();
|
||||
if (!this.state[appId] && create) {
|
||||
this.state[appId] = this.emptyState();
|
||||
}
|
||||
return (this.state[appId] = this.emptyState());
|
||||
return this.state[appId] || this.emptyState();
|
||||
};
|
||||
|
||||
public canLoadMore = (appId: number) => this.stateOf(appId, /*create*/ false).hasMore;
|
||||
|
|
|
|||
Loading…
Reference in New Issue