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(archive): all-archive should properly display when refreshing #551

Merged
merged 2 commits into from
Oct 12, 2022

Conversation

tthvo
Copy link
Member

@tthvo tthvo commented Oct 12, 2022

Fixes #549

Fixes

All Archive view now correctly refresh view when auto-refresh is enabled. The issue was that there is a call to Array.includes, which only checks object reference.

Chore

Counts of archives for each target should not be an saved in an array (i.e. sorting might be supported). Alternative was Map<string, number> with key is target.connectUrl. This way, subscriptions to notification channel are only called once in React.useEffect for each type.

@tthvo tthvo added the fix label Oct 12, 2022
@tthvo tthvo added the chore Refactor, rename, cleanup, etc. label Oct 12, 2022
Copy link
Member

@maxcao13 maxcao13 left a comment

Choose a reason for hiding this comment

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

LGTM, bug is fixed.

@andrewazores andrewazores merged commit 770ace9 into cryostatio:main Oct 12, 2022
@tthvo tthvo deleted the fix-all-archives branch October 12, 2022 20:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Refactor, rename, cleanup, etc. fix
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[Task] Refreshing causes incorrect display of All-Archives view
3 participants