Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(electron): keep defaultWebPreferences field #3498

Merged
merged 1 commit into from
Apr 10, 2024

Conversation

leavesster
Copy link
Contributor

…nces don't have these fields

Types

  • 🐛 Bug Fixes

Background or solution

如果 loadWorkspace API 的 options 参数中包含 webPreferences 字段的话,目前这个 options 的 webPreferences 直接覆盖原有的所有内容,导致启动前端 preload 等失败。 options 的 webPreferences 应该放到默认参数里面的,进行展开操作。

Changelog

fix: default webPreference filed should be left if options webPreferences don't have these fields

@opensumi opensumi bot added the 🐞 bug Something isn't working label Apr 7, 2024
@leavesster leavesster force-pushed the fix-webPreference branch 2 times, most recently from 8026f73 to ab56f69 Compare April 9, 2024 02:06
Copy link

codecov bot commented Apr 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 56.59%. Comparing base (5532540) to head (d85fe16).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3498      +/-   ##
==========================================
- Coverage   56.60%   56.59%   -0.02%     
==========================================
  Files        1461     1461              
  Lines       89926    89926              
  Branches    17493    18510    +1017     
==========================================
- Hits        50902    50891      -11     
+ Misses      39001    35526    -3475     
- Partials       23     3509    +3486     
Flag Coverage Δ
jsdom 51.89% <ø> (-0.02%) ⬇️
node 15.81% <ø> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bytemain bytemain changed the title fix: default webPreference filed should be left if options webPreferences don't have these fields fix(electron): keep defaultWebPreferences field Apr 10, 2024
@bytemain bytemain merged commit 55b36cc into opensumi:main Apr 10, 2024
11 checks passed
@leavesster leavesster deleted the fix-webPreference branch April 10, 2024 05:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants