fixed filelist sync on initial login and after upload

This commit is contained in:
Danny Coates 2018-12-12 10:14:06 -08:00
parent e58ebc835c
commit 09a4d7b9ee
No known key found for this signature in database
GPG key ID: 4C442633C62E00CB
2 changed files with 3 additions and 4 deletions

View file

@ -40,8 +40,6 @@ export default function(state, emitter) {
checkFiles();
});
emitter.on('navigate', checkFiles);
emitter.on('render', () => {
lastRender = Date.now();
});
@ -174,6 +172,7 @@ export default function(state, emitter) {
emitter.emit('pushState', '/error');
}
} finally {
await state.user.syncFileList();
openLinksInNewTab(links, false);
state.archive = null;
state.password = '';
@ -265,8 +264,7 @@ export default function(state, emitter) {
});
setInterval(() => {
// poll for updates of the download counts
// TODO something for the share page: || state.route === '/share/:id'
// poll for updates of the upload list
if (state.route === '/') {
checkFiles();
}