Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions js/editor.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/editor.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/files.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/files.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/public.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/public.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/text.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/viewer.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/viewer.js.map

Large diffs are not rendered by default.

8 changes: 7 additions & 1 deletion src/services/PollingBackend.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ class PollingBackend {
}

connect() {
this.initialLoadingFinished = false
this.fetcher = setInterval(this._fetchSteps.bind(this), 50)
document.addEventListener('visibilitychange', this.visibilitychange.bind(this))
}
Expand Down Expand Up @@ -136,6 +137,9 @@ class PollingBackend {
this._authority.sessions = response.data.sessions

if (response.data.steps.length === 0) {
if (!this.initialLoadingFinished) {
this.initialLoadingFinished = true
}
if (this._authority.checkIdle()) {
return
}
Expand All @@ -153,7 +157,9 @@ class PollingBackend {
this._authority._receiveSteps(response.data)
this.lock = false
this._forcedSave = false
this.resetRefetchTimer()
if (this.initialLoadingFinished) {
this.resetRefetchTimer()
}
}).catch((e) => {
this.lock = false
if (!e.response || e.code === 'ECONNABORTED') {
Expand Down