Skip to content

Commit

Permalink
Merge pull request #8 from mbehr1/fix_issue_7
Browse files Browse the repository at this point in the history
fix(report): queued msgs to webview should be in fifo order
  • Loading branch information
mbehr1 authored Jan 4, 2021
2 parents ed30e49 + a165838 commit 1588e43
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dltReport.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export class DltReport implements vscode.Disposable {
// any messages to post?
if (this._msgsToPost.length) {
let msg: any;
while (msg = this._msgsToPost.pop()) {
while (msg = this._msgsToPost.shift()) { // fifo order.
const msgCmd = msg.command;
this.panel?.webview.postMessage(msg).then((onFulFilled) => {
console.log(`webview.postMessage(${msgCmd}) queued ${onFulFilled}`);
Expand Down Expand Up @@ -400,4 +400,4 @@ export class DltReport implements vscode.Disposable {
}

}
}
}

0 comments on commit 1588e43

Please sign in to comment.