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

[shelly] Fix suggestion finder #17696

Merged
merged 1 commit into from
Nov 4, 2024
Merged

Conversation

jlaur
Copy link
Contributor

@jlaur jlaur commented Nov 3, 2024

My PM Mini is discovered as name starting with "shelly" (lowercase):
image

Making the matching case-insensitive is consistent with the logic in code:

public DiscoveryResult createResult(final ServiceInfo service) {
String name = service.getName().toLowerCase(); // Shelly Duo: Name starts with" Shelly" rather than "shelly"
if (!name.startsWith("shelly")) {
return null;
}

Regression of #15817

Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
@jlaur jlaur added the bug An unexpected problem or unintended behavior of an add-on label Nov 3, 2024
@jlaur jlaur requested a review from markus7017 as a code owner November 3, 2024 21:35
@jlaur jlaur requested a review from a team November 3, 2024 21:36
Copy link
Member

@holgerfriedrich holgerfriedrich left a comment

Choose a reason for hiding this comment

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

LGTM

@lsiepel lsiepel merged commit 3fef5cc into openhab:main Nov 4, 2024
5 checks passed
@lsiepel lsiepel added this to the 4.3 milestone Nov 4, 2024
@jlaur jlaur deleted the shelly-suggestion-finder branch November 4, 2024 21:07
KaaNee pushed a commit to KaaNee/openhab-addons that referenced this pull request Nov 8, 2024
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
matchews pushed a commit to matchews/openhab-addons that referenced this pull request Dec 16, 2024
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
cipianpascu pushed a commit to cipianpascu/openhab-addons that referenced this pull request Jan 2, 2025
Signed-off-by: Jacob Laursen <jacob-github@vindvejr.dk>
Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior of an add-on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants