|
|
@@ -2004,13 +2004,12 @@ func runServer(t *testing.T, runConfig *runServerConfig) {
|
|
|
|
|
|
case "InproxyProxyTotalActivity":
|
|
|
|
|
|
- // This assumes that both non-zero bytes up and down are
|
|
|
- // reported in at least same notice, although there's some
|
|
|
- // unlikely chance it's only one or the other.
|
|
|
+ // Bytes aren't checked here since there's a chance that the
|
|
|
+ // last infrequent InproxyProxyTotalActivity notice is posted
|
|
|
+ // before any upstream relay.
|
|
|
+
|
|
|
connectedClients := int(payload["connectedClients"].(float64))
|
|
|
- bytesUp := int(payload["totalBytesUp"].(float64))
|
|
|
- bytesDown := int(payload["totalBytesDown"].(float64))
|
|
|
- if connectedClients == 1 && bytesUp > 0 && bytesDown > 0 {
|
|
|
+ if connectedClients == 1 {
|
|
|
sendNotificationReceived(inproxyActivity)
|
|
|
}
|
|
|
|