Fix redundant error message about admin rights (#1426)

This commit is contained in:
Alexander Zinchuk 2021-09-06 15:29:10 +03:00
parent e01ccf27d4
commit dde6477236
2 changed files with 4 additions and 3 deletions

View File

@ -250,7 +250,7 @@ const Composer: FC<OwnProps & StateProps & DispatchProps> = ({
useEffect(() => {
if (chatId && lastSyncTime && threadId === MAIN_THREAD_ID && isReady) {
loadScheduledHistory();
loadScheduledHistory({ chatId });
}
}, [isReady, chatId, loadScheduledHistory, lastSyncTime, threadId]);

View File

@ -558,8 +558,9 @@ addReducer('forwardMessages', (global) => {
}
});
addReducer('loadScheduledHistory', (global) => {
const chat = selectCurrentChat(global);
addReducer('loadScheduledHistory', (global, actions, payload) => {
const { chatId } = payload;
const chat = selectChat(global, chatId);
if (!chat) {
return;
}