/*
- * jSite - UpdateChecker.java - Copyright © 2008–2012 David Roden
+ * jSite - UpdateChecker.java - Copyright © 2008–2014 David Roden
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
import java.util.logging.Logger;
import net.pterodactylus.util.io.Closer;
-import de.todesbaum.jsite.main.Main;
import de.todesbaum.jsite.main.Version;
import de.todesbaum.util.freenet.fcp2.Client;
import de.todesbaum.util.freenet.fcp2.ClientGet;
private static int counter = 0;
/** The edition for the update check URL. */
- private static final int UPDATE_EDITION = 18;
+ private static final int UPDATE_EDITION = 11;
/** The URL for update checks. */
- private static final String UPDATE_KEY = "USK@e3myoFyp5avg6WYN16ImHri6J7Nj8980Fm~aQe4EX1U,QvbWT0ImE0TwLODTl7EoJx2NBnwDxTbLTE6zkB-eGPs,AQACAAE";
+ private static final String UPDATE_KEY = "USK@1waTsw46L9-JEQ8yX1khjkfHcn--g0MlMsTlYHax9zQ,oYyxr5jyFnaTsVGDQWk9e3ddOWGKnqEASxAk08MHT2Y,AQACAAE";
/** Object used for synchronization. */
private final Object syncObject = new Object();
private int lastUpdateEdition = UPDATE_EDITION;
/** Last found version. */
- private Version lastVersion = Main.getVersion();
+ private Version lastVersion;
/** The freenet interface. */
private final Freenet7Interface freenetInterface;
* @param freenetInterface
* The freenet interface
*/
- public UpdateChecker(Freenet7Interface freenetInterface) {
+ public UpdateChecker(Freenet7Interface freenetInterface, Version currentVersion) {
this.freenetInterface = freenetInterface;
+ this.lastVersion = currentVersion;
}
//