LocalInsightPlugin crash fix

This commit is contained in:
Milos Kozak 2020-03-06 19:02:34 +01:00
parent 90a9b09395
commit 6fa05f11c9

View file

@ -937,6 +937,7 @@ public class LocalInsightPlugin extends PluginBase implements PumpInterface, Con
@Override @Override
public JSONObject getJSONStatus(Profile profile, String profileName) { public JSONObject getJSONStatus(Profile profile, String profileName) {
long now = System.currentTimeMillis(); long now = System.currentTimeMillis();
if (connectionService == null) return null;
if (System.currentTimeMillis() - connectionService.getLastConnected() > (60 * 60 * 1000)) { if (System.currentTimeMillis() - connectionService.getLastConnected() > (60 * 60 * 1000)) {
return null; return null;
} }