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 loading collaborators from storage #4522

Merged
merged 2 commits into from
Nov 21, 2023
Merged

Fix loading collaborators from storage #4522

merged 2 commits into from
Nov 21, 2023

Conversation

ruggi
Copy link
Contributor

@ruggi ruggi commented Nov 21, 2023

Fix #4521

Problem:

The new collaborators storage logic has two problems:

  1. the userbar info uses the current user meta instead of the other data
  2. loading users meta from the collabs object may return a null (for collaborators not yet stored), which would break the whole multiplayer

Fix:

  1. use the right data
  2. make sure to return a default placeholder meta object if collaborators[id] is null, which will be replaced with the right meta once it's available in the storage
  3. add a helper to safely get a collaborator meta

Copy link
Contributor

github-actions bot commented Nov 21, 2023

Try me

Copy link

relativeci bot commented Nov 21, 2023

Job #9246: Bundle Size — 65.58MiB (~+0.01%).

d2d8401(current) vs 5957b21 master#9237(baseline)

Warning

Bundle contains 67 duplicate packages – View duplicate packages

Bundle metrics  Change 1 change Regression 1 regression
                 Current
Job #9246
     Baseline
Job #9237
Regression  Initial JS 47.73MiB(~+0.01%) 47.73MiB
No change  Initial CSS 0B 0B
No change  Cache Invalidation 18.32% 18.32%
No change  Chunks 25 25
No change  Assets 29 29
No change  Modules 4420 4420
No change  Duplicate Modules 469 469
No change  Duplicate Code 30.17% 30.17%
No change  Packages 458 458
No change  Duplicate Packages 67 67
Bundle size by type  Change 1 change Regression 1 regression
                 Current
Job #9246
     Baseline
Job #9237
Regression  JS 65.57MiB (~+0.01%) 65.57MiB
Not changed  HTML 11.32KiB 11.32KiB

View job #9246 reportView fix/collab-loading branch activity

Copy link
Contributor

Performance test results:
(Chart1)
(Chart2)

@gbalint gbalint merged commit 3d99ac7 into master Nov 21, 2023
11 checks passed
@gbalint gbalint deleted the fix/collab-loading branch November 21, 2023 10:47
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.

Fix loading collaborators
3 participants