forked from I2P_Developers/i2p.i2p
Update: Make backup news URL configurable (see gitlab MR !33)
This commit is contained in:
@@ -25,7 +25,7 @@ class NewsHandler extends UpdateHandler implements Checker {
|
||||
* NOTE: If you change, also change in Android:
|
||||
* app/src/main/java/net/i2p/android/apps/NewsFetcher.java
|
||||
*
|
||||
* @since 0.7.14 not configurable
|
||||
* @since 0.7.14, configurable since 0.9.51
|
||||
*/
|
||||
// psi.i2p
|
||||
//private static final String BACKUP_NEWS_URL = "http://avviiexdngd32ccoy4kuckvc3mkf53ycvzbz6vz75vzhv4tbpk5a.b32.i2p/news.xml";
|
||||
@@ -35,7 +35,8 @@ class NewsHandler extends UpdateHandler implements Checker {
|
||||
//private static final String BACKUP_NEWS_URL_SU3 = "http://ivk5a6wfjar6hjucjmnbcea5inwmwg5b3hsv72x77xwyhbeaajja.b32.i2p/news/news.su3";
|
||||
// idk
|
||||
private static final String BACKUP_NEWS_URL = "http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/news.atom.xml";
|
||||
private static final String BACKUP_NEWS_URL_SU3 = "http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/news.su3";
|
||||
private static final String DEFAULT_BACKUP_NEWS_URL_SU3 = "http://dn3tvalnjz432qkqsvpfdqrwpqkw3ye4n4i2uyfr4jexvo3sp5ka.b32.i2p/news/news.su3";
|
||||
private static final String PROP_BACKUP_NEWS_URL_SU3 = "router.backupNewsURL";
|
||||
|
||||
public NewsHandler(RouterContext ctx, ConsoleUpdateManager mgr) {
|
||||
super(ctx, mgr);
|
||||
@@ -58,7 +59,7 @@ class NewsHandler extends UpdateHandler implements Checker {
|
||||
} catch (URISyntaxException use) {}
|
||||
try {
|
||||
//updateSources.add(new URI(BACKUP_NEWS_URL));
|
||||
updateSources.add(new URI(BACKUP_NEWS_URL_SU3));
|
||||
updateSources.add(new URI(_context.getProperty(PROP_BACKUP_NEWS_URL_SU3, DEFAULT_BACKUP_NEWS_URL_SU3)));
|
||||
} catch (URISyntaxException use) {}
|
||||
UpdateRunner update = new NewsFetcher(_context, _mgr, updateSources);
|
||||
return update;
|
||||
|
||||
Reference in New Issue
Block a user