mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #17863 from overleaf/ar-set-socket-disconnect-timeout-to-match-wire-value
Set socket disconnect timeout to match wire value GitOrigin-RevId: b3bfc460090b872500b55b0d5e2167b828ef31f4
This commit is contained in:
parent
d35204033f
commit
6100954635
2 changed files with 4 additions and 2 deletions
|
@ -219,13 +219,15 @@ export class ConnectionManager extends EventTarget {
|
|||
clearInterval(this.idleDisconnectInterval)
|
||||
clearTimeout(this.reconnectCountdownInterval)
|
||||
window.removeEventListener('online', this.onOnline)
|
||||
|
||||
window.setTimeout(() => this.disconnect(), 1000 * delay)
|
||||
|
||||
this.changeState({
|
||||
...this.state,
|
||||
forceDisconnected: true,
|
||||
forcedDisconnectDelay: delay,
|
||||
error,
|
||||
})
|
||||
setTimeout(() => this.disconnect(), 1000)
|
||||
}
|
||||
|
||||
private onJoinProjectResponse({
|
||||
|
|
|
@ -253,7 +253,7 @@ export default ConnectionManager = (function () {
|
|||
})
|
||||
// flush changes before disconnecting
|
||||
this.ide.$scope.$broadcast('flush-changes')
|
||||
setTimeout(() => this.ide.socket.disconnect(), 1000)
|
||||
window.setTimeout(() => this.ide.socket.disconnect(), 1000 * delay)
|
||||
this.ide.showLockEditorMessageModal(
|
||||
'Please wait',
|
||||
`\
|
||||
|
|
Loading…
Reference in a new issue