continue;
}
- InsertInformation insertInformation = null;
+ boolean insertSoneNow = false;
synchronized (sone) {
String fingerprint = sone.getFingerprint();
if (!fingerprint.equals(lastFingerprint)) {
}
if (modified && lastModificationTime.isPresent() && ((currentTimeMillis() - lastModificationTime.get()) > (insertionDelay * 1000))) {
lastInsertedFingerprint = fingerprint;
- insertInformation = new InsertInformation(sone);
+ insertSoneNow = true;
}
}
- if (insertInformation != null) {
+ if (insertSoneNow) {
+ InsertInformation insertInformation = new InsertInformation(sone);
logger.log(Level.INFO, String.format("Inserting Sone “%s”…", sone.getName()));
boolean success = false;