Merge branch 'master' into clearnet

pull/1656/head
Audric Ackermann 4 years ago committed by GitHub
commit a24e0ccb32
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -8,6 +8,7 @@ import { UserUtils } from '../../session/utils';
import { syncConfigurationIfNeeded } from '../../session/utils/syncUtils';
import { DAYS, MINUTES } from '../../session/utils/Number';
import {
createOrUpdateItem,
generateAttachmentKeyIfEmpty,
getItemById,
hasSyncedInitialConfigurationItem,
@ -44,6 +45,20 @@ export enum SectionType {
Moon,
}
const showUnstableAttachmentsDialogIfNeeded = async () => {
const alreadyShown = (await getItemById('showUnstableAttachmentsDialog'))?.value;
if (!alreadyShown) {
window.confirmationDialog({
title: 'File server update',
message:
"We're upgrading the way files are stored. File transfer may be unstable for the next 24-48 hours.",
});
await createOrUpdateItem({ id: 'showUnstableAttachmentsDialog', value: true });
}
};
const Section = (props: { type: SectionType; avatarPath?: string }) => {
const ourNumber = useSelector(getOurNumber);
const unreadMessageCount = useSelector(getUnreadMessageCount);
@ -157,6 +172,7 @@ const doAppStartUp = (dispatch: Dispatch<any>) => {
void OnionPaths.getInstance().buildNewOnionPaths();
}
void showUnstableAttachmentsDialogIfNeeded();
// init the messageQueue. In the constructor, we add all not send messages
// this call does nothing except calling the constructor, which will continue sending message in the pipeline
void getMessageQueue().processAllPending();

Loading…
Cancel
Save