X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsone%2Fcore%2FSoneInserter.java;h=1e93aa67229bca4fa4a8741ba8346bb51ee78bd3;hp=729f434b723f3be14b0ca0308a32a49d9cddf1e5;hb=c74a6b50636ab4c13967ac90fa4155eea028b836;hpb=283043745205f86bcf7bf5144ecf437063aed102 diff --git a/src/main/java/net/pterodactylus/sone/core/SoneInserter.java b/src/main/java/net/pterodactylus/sone/core/SoneInserter.java index 729f434..1e93aa6 100644 --- a/src/main/java/net/pterodactylus/sone/core/SoneInserter.java +++ b/src/main/java/net/pterodactylus/sone/core/SoneInserter.java @@ -116,12 +116,17 @@ public class SoneInserter extends AbstractService { * The Sone to insert */ public SoneInserter(Core core, EventBus eventBus, FreenetInterface freenetInterface, Sone sone) { + this(core, eventBus, freenetInterface, sone, new SoneModificationDetector(core, sone, insertionDelay)); + } + + @VisibleForTesting + SoneInserter(Core core, EventBus eventBus, FreenetInterface freenetInterface, Sone sone, SoneModificationDetector soneModificationDetector) { super("Sone Inserter for “" + sone.getName() + "”", false); this.core = core; this.eventBus = eventBus; this.freenetInterface = freenetInterface; this.sone = sone; - this.soneModificationDetector = new SoneModificationDetector(core, sone, insertionDelay); + this.soneModificationDetector = soneModificationDetector; } //