diff --git a/customize.dist/translations/messages.fr.js b/customize.dist/translations/messages.fr.js index 64b40f553..70d804652 100644 --- a/customize.dist/translations/messages.fr.js +++ b/customize.dist/translations/messages.fr.js @@ -283,6 +283,8 @@ define(function () { out.fo_unableToRestore = "Impossible de restaurer ce fichier à son emplacement d'origine. Vous pouvez essayer de le déplacer à un nouvel emplacement."; out.fo_unavailableName = "Un fichier ou dossier avec le même nom existe déjà au nouvel emplacement. Renommez cet élément avant d'essayer à nouveau."; + out.fs_migration = "Votre CryptDrive est en train d'être mis à jour vers une nouvelle version. Cela implique que cette page doive être rechargée.
Veuillez recharger la page pour pouvoir continuer à l'utiliser."; + // login out.login_login = "Connexion"; out.login_makeAPad = 'Créer un pad anonymement'; diff --git a/customize.dist/translations/messages.js b/customize.dist/translations/messages.js index fa08fb1c7..6d4f07c02 100644 --- a/customize.dist/translations/messages.js +++ b/customize.dist/translations/messages.js @@ -285,6 +285,8 @@ define(function () { out.fo_unableToRestore = "Unable to restore that file to its original location. You can try to move it to a new location."; out.fo_unavailableName = "A file or a folder with the same name already exist at the new location. Rename the element and try again."; + out.fs_migration = "Your CryptDrive is being updated to a new version. As a result, the current page has to be reloaded.
Please reload this page to continue to use it."; + // login out.login_login = "Log in"; out.login_makeAPad = 'Create a pad anonymously'; diff --git a/www/common/fsStore.js b/www/common/fsStore.js index 2fa5f87cd..21a92c75a 100644 --- a/www/common/fsStore.js +++ b/www/common/fsStore.js @@ -297,19 +297,15 @@ define([ return; } }) - .on('change', [], function () { + .on('change', ['drive', 'migrate'], function () { var path = arguments[2]; var value = arguments[1]; - console.log('abcd'); - console.log(arguments); - if (path[0] === 'drive' && path[1] === "migrate" && value === 1) { - console.log('PEWPEWPEW'); + if (path[0] === 'drive' && path[1] === "migrate" && value == 1) { rt.network.disconnect(); rt.realtime.abort(); - Cryptpad.alert("Disconnected while migration"); + Cryptpad.alert(Cryptpad.Messages.fs_migration); } }); - }; Store.ready = function (f, Cryptpad) { diff --git a/www/drive/main.js b/www/drive/main.js index 16659786b..85fe00d50 100644 --- a/www/drive/main.js +++ b/www/drive/main.js @@ -2504,7 +2504,6 @@ define([ module.resetTree(); return false; }).on('change', ['drive', 'migrate'], function () { - console.log('OKOKOK'); var path = arguments[2]; var value = arguments[1]; if (path[1] === "migrate" && value === 1) {