diff --git a/app/src/processing/app/UpdateCheck.java b/app/src/processing/app/UpdateCheck.java index 39c555069a1..5350c8fd609 100644 --- a/app/src/processing/app/UpdateCheck.java +++ b/app/src/processing/app/UpdateCheck.java @@ -66,14 +66,14 @@ public UpdateCheck(Base base) { public void run() { //System.out.println("checking for updates..."); - // generate a random id in case none exists yet - Random r = new Random(); - long id = r.nextLong(); - + long id; String idString = PreferencesData.get("update.id"); if (idString != null) { id = Long.parseLong(idString); } else { + // generate a random id in case none exists yet + Random r = new Random(); + id = r.nextLong(); PreferencesData.set("update.id", String.valueOf(id)); }