We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ab842b9 commit 88006acCopy full SHA for 88006ac
src/connection/embedded_connection.ts
@@ -24,15 +24,15 @@ export class EmbeddedConnection implements Connection {
24
if (len === 1) {
25
// we are the first in line, therefore we schedule a flush,
26
// BUT we must wait for the previous flush to end.
27
- //
28
this.flushing = this.flushing.then(() => this.scheduleFlush());
29
}
30
// tag along to the previously scheduled flush.
31
return this.flushing;
32
33
34
end(): Promise<void> {
35
- return this.flush();
+ this.flushing = this.flushing.then(() => this.flush());
+ return this.flushing;
36
37
38
private scheduleFlush(): Promise<void> {
0 commit comments