I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 4f5e3401 authored by zzz's avatar zzz
Browse files

change default news fetch to 36 hours

parent 81beb639
No related branches found
No related tags found
No related merge requests found
...@@ -24,7 +24,7 @@ public class ConfigUpdateHandler extends FormHandler { ...@@ -24,7 +24,7 @@ public class ConfigUpdateHandler extends FormHandler {
public static final String OLD_DEFAULT_NEWS_URL = "http://complication.i2p/news.xml"; public static final String OLD_DEFAULT_NEWS_URL = "http://complication.i2p/news.xml";
public static final String DEFAULT_NEWS_URL = "http://echelon.i2p/i2p/news.xml"; public static final String DEFAULT_NEWS_URL = "http://echelon.i2p/i2p/news.xml";
public static final String PROP_REFRESH_FREQUENCY = "router.newsRefreshFrequency"; public static final String PROP_REFRESH_FREQUENCY = "router.newsRefreshFrequency";
public static final String DEFAULT_REFRESH_FREQUENCY = 24*60*60*1000 + ""; public static final String DEFAULT_REFRESH_FREQUENCY = 36*60*60*1000 + "";
public static final String PROP_UPDATE_POLICY = "router.updatePolicy"; public static final String PROP_UPDATE_POLICY = "router.updatePolicy";
public static final String DEFAULT_UPDATE_POLICY = "download"; public static final String DEFAULT_UPDATE_POLICY = "download";
public static final String PROP_SHOULD_PROXY = "router.updateThroughProxy"; public static final String PROP_SHOULD_PROXY = "router.updateThroughProxy";
......
...@@ -67,11 +67,14 @@ public class ConfigUpdateHelper extends HelperBase { ...@@ -67,11 +67,14 @@ public class ConfigUpdateHelper extends HelperBase {
return "<input type=\"checkbox\" class=\"optbox\" value=\"true\" name=\"updateUnsigned\" >"; return "<input type=\"checkbox\" class=\"optbox\" value=\"true\" name=\"updateUnsigned\" >";
} }
private static final long PERIODS[] = new long[] { 12*60*60*1000l, 24*60*60*1000l, 48*60*60*1000l, -1l }; private static final long PERIODS[] = new long[] { 12*60*60*1000l, 24*60*60*1000l,
36*60*60*1000l, 48*60*60*1000l,
3*24*60*60*1000l, 7*24*60*60*1000l,
-1l };
public String getRefreshFrequencySelectBox() { public String getRefreshFrequencySelectBox() {
String freq = _context.getProperty(ConfigUpdateHandler.PROP_REFRESH_FREQUENCY); String freq = _context.getProperty(ConfigUpdateHandler.PROP_REFRESH_FREQUENCY,
if (freq == null) freq = ConfigUpdateHandler.DEFAULT_REFRESH_FREQUENCY; ConfigUpdateHandler.DEFAULT_REFRESH_FREQUENCY);
long ms = -1; long ms = -1;
try { try {
ms = Long.parseLong(freq); ms = Long.parseLong(freq);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment