diff --git a/apps/routerconsole/java/src/net/i2p/router/update/ConsoleUpdateManager.java b/apps/routerconsole/java/src/net/i2p/router/update/ConsoleUpdateManager.java index d34492294b..d3b0b45a80 100644 --- a/apps/routerconsole/java/src/net/i2p/router/update/ConsoleUpdateManager.java +++ b/apps/routerconsole/java/src/net/i2p/router/update/ConsoleUpdateManager.java @@ -142,6 +142,9 @@ public class ConsoleUpdateManager implements UpdateManager, RouterApp { notifyInstalled(ROUTER_SIGNED, "", RouterVersion.VERSION); notifyInstalled(ROUTER_SIGNED_SU3, "", RouterVersion.VERSION); notifyInstalled(ROUTER_DEV_SU3, "", RouterVersion.FULL_VERSION); + String blist = _context.getProperty(NewsFetcher.PROP_BLOCKLIST_TIME); + if (blist != null) + notifyInstalled(BLOCKLIST, "", blist); // hack to init from the current news file... do this before we register Updaters // This will not kick off any Updaters as none are yet registered (new NewsFetcher(_context, this, Collections. emptyList())).checkForUpdates(); @@ -789,7 +792,7 @@ public class ConsoleUpdateManager implements UpdateManager, RouterApp { UpdateType type, String id, Map> sourceMap, String newVersion, String minVersion) { - if (type == NEWS || type == NEWS_SU3) { + if (type == NEWS || type == NEWS_SU3 || type == BLOCKLIST) { // shortcut notifyInstalled(type, "", newVersion); return true; diff --git a/apps/routerconsole/java/src/net/i2p/router/update/NewsFetcher.java b/apps/routerconsole/java/src/net/i2p/router/update/NewsFetcher.java index 2f39f1053b..51e14a44e9 100644 --- a/apps/routerconsole/java/src/net/i2p/router/update/NewsFetcher.java +++ b/apps/routerconsole/java/src/net/i2p/router/update/NewsFetcher.java @@ -77,7 +77,7 @@ class NewsFetcher extends UpdateRunner { private boolean _success; private static final String TEMP_NEWS_FILE = "news.xml.temp"; - private static final String PROP_BLOCKLIST_TIME = "router.blocklistVersion"; + static final String PROP_BLOCKLIST_TIME = "router.blocklistVersion"; private static final String BLOCKLIST_DIR = "docs/feed/blocklist"; private static final String BLOCKLIST_FILE = "blocklist.txt"; @@ -711,7 +711,10 @@ class NewsFetcher extends UpdateRunner { } if (!fail) { f.setLastModified(ble.updated); - _context.router().saveConfig(PROP_BLOCKLIST_TIME, Long.toString(ble.updated)); + String upd = Long.toString(ble.updated); + _context.router().saveConfig(PROP_BLOCKLIST_TIME, upd); + _mgr.notifyVersionAvailable(this, _currentURI, BLOCKLIST, "", HTTP, + null, upd, ""); } if (_log.shouldWarn()) _log.warn("Processed " + ble.entries.size() + " blocks and " + ble.removes.size() + " unblocks from news feed"); diff --git a/core/java/src/net/i2p/update/UpdateType.java b/core/java/src/net/i2p/update/UpdateType.java index cf26bec08f..8277df98c9 100644 --- a/core/java/src/net/i2p/update/UpdateType.java +++ b/core/java/src/net/i2p/update/UpdateType.java @@ -14,7 +14,6 @@ public enum UpdateType { PLUGIN, /** unused */ GEOIP, - /** unused */ BLOCKLIST, /** unused */ RESEED,