Skip to content

删除 uint8Array 重复封装#1340

Merged
CodFrm merged 2 commits intomainfrom
remove-uint8array-re-pack
Apr 8, 2026
Merged

删除 uint8Array 重复封装#1340
CodFrm merged 2 commits intomainfrom
remove-uint8array-re-pack

Conversation

@cyfung1031
Copy link
Copy Markdown
Collaborator

Checklist / 检查清单

  • Fixes mentioned issues / 修复已提及的问题
  • Code reviewed by human / 代码通过人工检查
  • Changes tested / 已完成测试

Description / 描述

Screenshots / 截图

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

该 PR 聚焦在 Service Worker 资源加载流程中,移除对 Uint8Array 的重复封装,避免不必要的对象创建,使资源内容类型判定逻辑更直接。

Changes:

  • loadByUrl()blobToUint8Array() 的返回值变量从误导性的 arrayBuffer 更正为 uint8Array
  • 删除 new Uint8Array(arrayBuffer) 的冗余封装,直接复用 blobToUint8Array() 的结果

@CodFrm CodFrm merged commit 39aff8a into main Apr 8, 2026
3 of 4 checks passed
@CodFrm CodFrm deleted the remove-uint8array-re-pack branch April 8, 2026 02:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants