File tree 1 file changed +7
-3
lines changed
arduino-core/src/processing/app
1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -899,9 +899,13 @@ public static void createToolPreferences(Collection<ContributedTool> installedTo
899
899
PreferencesData .set (prefix + toolName + "-" + toolVersion + ".path" , toolPath );
900
900
PreferencesData .set (prefix + tool .getPackager () + "-" + toolName + "-" + toolVersion + ".path" , toolPath );
901
901
// In the generic tool property put the path of the latest version if more are available
902
- if (!latestVersions .containsKey (toolName ) || comparator .greaterThan (toolVersion , latestVersions .get (toolName ))) {
903
- latestVersions .put (toolName , toolVersion );
904
- PreferencesData .set (prefix + toolName + ".path" , toolPath );
902
+ try {
903
+ if (!latestVersions .containsKey (toolName ) || comparator .greaterThan (toolVersion , latestVersions .get (toolName ))) {
904
+ latestVersions .put (toolName , toolVersion );
905
+ PreferencesData .set (prefix + toolName + ".path" , toolPath );
906
+ }
907
+ } catch (Exception e ) {
908
+ // Ignore invalid versions
905
909
}
906
910
}
907
911
}
You can’t perform that action at this time.
0 commit comments