Skip to content

table-formatter.js: Fix icon selection logic#2479

Merged
BareosBot merged 2 commits intobareos:masterfrom
bensmrs:fix-client-logos
Dec 12, 2025
Merged

table-formatter.js: Fix icon selection logic#2479
BareosBot merged 2 commits intobareos:masterfrom
bensmrs:fix-client-logos

Conversation

@bensmrs
Copy link
Contributor

@bensmrs bensmrs commented Dec 9, 2025

This fixes two problems:

  • It is not useful here to construct a map, and its iteration is broken (values() doesn’t do what’s expected here);
  • The Windows case would catch darwin because it contains win.

Thank you for contributing to the Bareos Project!

Please check

  • Short description and the purpose of this PR is present above this paragraph
    Your name is present in the AUTHORS file (optional)

If you have any questions or problems, please give a comment in the PR.

Helpful documentation and best practices

Checklist for the reviewer of the PR (will be processed by the Bareos team)

Make sure you check/merge the PR using devtools/pr-tool to have some simple automated checks run and a proper changelog record added.

General
  • Is the PR title usable as CHANGELOG entry?
  • Purpose of the PR is understood
  • Commit descriptions are understandable and well formatted
  • Required backport PRs have been created
  • Correct milestone is set
Source code quality
  • Source code changes are understandable
  • Variable and function names are meaningful
  • Code comments are correct (logically and spelling)
  • Required documentation changes are present and part of the PR

@bensmrs
Copy link
Contributor Author

bensmrs commented Dec 9, 2025

Before: Wrong behavior: macOS shown as Windows
After: Proper behavior: macOS shown as macOS

@sebsura
Copy link
Contributor

sebsura commented Dec 10, 2025

Do you want to add yourself to the AUTHORS file ?

@bensmrs
Copy link
Contributor Author

bensmrs commented Dec 10, 2025

Let’s wait for a big contribution, I’m not in a hurry :)
The future Incus FD plugin will be a better reason to call myself an “author”!

Copy link
Contributor

@sebsura sebsura left a comment

Choose a reason for hiding this comment

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

Thanks for the quick fix!

@sebsura sebsura added this to the 25.0.2 milestone Dec 12, 2025
@sebsura sebsura modified the milestones: 25.0.2, 26.0.0 Dec 12, 2025
This fixes two problems:
- It is not useful here to construct a map, and its iteration is
  broken (`values()` doesn’t do what’s expected here);
- The Windows case would catch `darwin` because it contains `win`.

Signed-off-by: Benjamin Somers <benjamin.somers@imt-atlantique.fr>
@BareosBot BareosBot merged commit b47c4cc into bareos:master Dec 12, 2025
1 check was pending
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants