mirror of
https://github.com/arduino/Arduino.git
synced 2024-11-29 10:24:12 +01:00
Handle duplicates of legacy libs correctly. (#3412)
This commit is contained in:
parent
98eb1a9ee2
commit
ba09c7511c
@ -142,7 +142,10 @@ public abstract class ContributedLibrary extends DownloadableContribution {
|
||||
String thisVersion = getParsedVersion();
|
||||
String otherVersion = ((ContributedLibrary) obj).getParsedVersion();
|
||||
|
||||
boolean versionEquals = thisVersion != null && otherVersion != null && thisVersion.equals(otherVersion);
|
||||
// Important: for legacy libs, versions are null. Two legacy libs must
|
||||
// always pass this test.
|
||||
boolean versionEquals = thisVersion == otherVersion ||
|
||||
(thisVersion != null && otherVersion != null && thisVersion.equals(otherVersion));
|
||||
|
||||
String thisName = getName();
|
||||
String otherName = ((ContributedLibrary) obj).getName();
|
||||
|
Loading…
Reference in New Issue
Block a user