mirror of
https://github.com/beemdevelopment/Aegis.git
synced 2025-06-08 15:47:47 +00:00
Merge pull request #780 from jhenninger/suggested-icons-matching
Improve icon suggestions
This commit is contained in:
commit
6585513120
1 changed files with 3 additions and 1 deletions
|
@ -162,8 +162,10 @@ public class IconPack {
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isSuggestedFor(String issuer) {
|
public boolean isSuggestedFor(String issuer) {
|
||||||
|
String lowerIssuer = issuer.toLowerCase();
|
||||||
return getIssuers().stream()
|
return getIssuers().stream()
|
||||||
.anyMatch(is -> is.toLowerCase().contains(issuer.toLowerCase()));
|
.map(String::toLowerCase)
|
||||||
|
.anyMatch(is -> is.contains(lowerIssuer) || lowerIssuer.contains(is));
|
||||||
}
|
}
|
||||||
|
|
||||||
public static Icon fromJson(JSONObject obj) throws JSONException {
|
public static Icon fromJson(JSONObject obj) throws JSONException {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue