Small simplification.
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Wed, 11 Jun 2014 04:05:20 +0000 (06:05 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Wed, 11 Jun 2014 04:05:20 +0000 (06:05 +0200)
src/main/java/net/pterodactylus/sone/core/SoneInserter.java

index 9e5d578..51882e9 100644 (file)
@@ -191,14 +191,13 @@ public class SoneInserter extends AbstractService {
                long lastModificationTime = 0;
                String lastInsertedFingerprint = lastInsertFingerprint;
                String lastFingerprint = "";
-               Sone sone;
                while (!shouldStop()) {
                        try {
                                /* check every second. */
                                sleep(1000);
 
                                /* don’t insert locked Sones. */
-                               sone = this.sone;
+                               Sone sone = this.sone;
                                if (core.isLocked(sone)) {
                                        /* trigger redetection when the Sone is unlocked. */
                                        synchronized (sone) {