瀏覽代碼

Set internal message ID to nextId after handling pending messages (#9463)

* Set internal message ID to nextId after handling pending messages

* add change file

* update bundle

* update reference.md

---------

Co-authored-by: Lucas Nogueira <lucas@tauri.app>
Graham Held 1 年之前
父節點
當前提交
cf615e8e4d
共有 3 個文件被更改,包括 6 次插入0 次删除
  1. 5 0
      .changes/fix-channel-buffer-processing.md
  2. 0 0
      core/tauri/scripts/bundle.global.js
  3. 1 0
      tooling/api/src/core.ts

+ 5 - 0
.changes/fix-channel-buffer-processing.md

@@ -0,0 +1,5 @@
+---
+"@tauri-apps/api": patch:bug
+---
+
+Fixes a bug when processing channel messages out of order.

文件差異過大導致無法顯示
+ 0 - 0
core/tauri/scripts/bundle.global.js


+ 1 - 0
tooling/api/src/core.ts

@@ -63,6 +63,7 @@ class Channel<T = unknown> {
                 break
               }
             }
+            this.#nextMessageId = nextId
           }
         } else {
           this.#pendingMessages[id.toString()] = message

部分文件因文件數量過多而無法顯示