File tree Expand file tree Collapse file tree 3 files changed +6
-80
lines changed
src/main/java/com/airsquared/blobsaver Expand file tree Collapse file tree 3 files changed +6
-80
lines changed Original file line number Diff line number Diff line change 3535
3636public class Main {
3737
38- static final Version appVersion = new Version ( "2 .3.1") ;
38+ static final String appVersion = "v2 .3.1" ;
3939 static final Preferences appPrefs = Preferences .userRoot ().node ("airsquared/blobsaver/prefs" );
4040 private static final String appID = "com.airsquared.blobsaver" ;
4141 static Stage primaryStage ;
Original file line number Diff line number Diff line change @@ -102,20 +102,20 @@ protected Void call() throws Exception {
102102 e .printStackTrace ();
103103 return null ;
104104 }
105- Version newVersion ;
105+ String newVersion ;
106106 String changelog ;
107107 try {
108- newVersion = new Version ( new JSONObject (response ).getString ("tag_name" ) );
108+ newVersion = new JSONObject (response ).getString ("tag_name" );
109109 changelog = new JSONObject (response ).getString ("body" );
110110 changelog = changelog .substring (changelog .indexOf ("Changelog" ));
111111 } catch (JSONException e ) {
112112 newVersion = appVersion ;
113113 changelog = "" ;
114114 }
115- if (newVersion . compareTo ( appVersion ) < 0 //check if this is >= latest version
116- && (forceCheck || !appPrefs .get ("Ignore Version" , "" ).equals (newVersion . toString () ))) {
115+ if (! appVersion . equals ( newVersion ) &&
116+ (forceCheck || !appPrefs .get ("Ignore Version" , "" ).equals (newVersion ))) {
117117 final CountDownLatch latch = new CountDownLatch (1 );
118- final String finalNewVersion = newVersion . toString () ; //so that the lambda works
118+ final String finalNewVersion = newVersion ; //so that the lambda works
119119 final String finalChangelog = changelog ;
120120 Platform .runLater (() -> {
121121 try {
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments