Dont show firewall warning unless its for real
This commit is contained in:
@ -154,6 +154,18 @@ public class SummaryHelper extends HelperBase {
|
||||
else
|
||||
return _context.commSystem().countActivePeers();
|
||||
}
|
||||
|
||||
/**
|
||||
* Should we warn about a possible firewall problem?
|
||||
*/
|
||||
public boolean showFirewallWarning() {
|
||||
return _context != null &&
|
||||
_context.netDb().isInitialized() &&
|
||||
_context.router().getUptime() > 2*60*1000 &&
|
||||
_context.commSystem().countActivePeers() <= 0 &&
|
||||
_context.netDb().getKnownRouters() > 5;
|
||||
}
|
||||
|
||||
/**
|
||||
* How many active identities have we spoken with recently
|
||||
*
|
||||
|
@ -92,7 +92,7 @@
|
||||
<tr><td align="left"><b>High capacity:</b></td><td align="right"><jsp:getProperty name="helper" property="highCapacityPeers" /></td></tr>
|
||||
<tr><td align="left"><b>Integrated:</b></td><td align="right"><jsp:getProperty name="helper" property="wellIntegratedPeers" /></td></tr>
|
||||
<tr><td align="left"><b>Known:</b></td><td align="right"><jsp:getProperty name="helper" property="allPeers" /></td></tr></table><hr><%
|
||||
if (helper.getActivePeers() <= 0) {
|
||||
if (helper.showFirewallWarning()) {
|
||||
%><h4><a href="config.jsp" target="_top" title="Help with firewall configuration.">Check NAT/firewall</a></h4><%
|
||||
}
|
||||
// If showing the reseed link is allowed
|
||||
|
Reference in New Issue
Block a user