Skip to content

[client] Fix unnecessary UI updates #3785

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

[client] Fix unnecessary UI updates #3785

wants to merge 1 commit into from

Conversation

lixmal
Copy link
Contributor

@lixmal lixmal commented May 5, 2025

Describe your changes

Issue ticket number and link

Stack

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

@Copilot Copilot AI review requested due to automatic review settings May 5, 2025 14:54
Copy link
Contributor

@Copilot 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

This PR fixes unnecessary UI updates by adding an additional condition when the system status is "connected".

  • Ensures UI updates occur only when s.mUp is not disabled.

@@ -526,7 +526,7 @@ func (s *serviceClient) updateStatus() error {
var systrayIconState bool

switch {
Copy link
Preview

Copilot AI May 5, 2025

Choose a reason for hiding this comment

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

[nitpick] Consider adding a comment explaining why the condition '!s.mUp.Disabled()' is required to improve clarity for future maintainers.

Suggested change
switch {
switch {
// Ensure the "Up" menu item is not disabled before proceeding with the connected status logic.

Copilot uses AI. Check for mistakes.

Copy link

sonarqubecloud bot commented May 5, 2025

@lixmal lixmal changed the title [client] Fix unncessary UI updates [client] Fix unnecessary UI updates May 5, 2025
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.

1 participant