diff --git a/src/main/java/globalquake/database/SeedlinkCommunicator.java b/src/main/java/globalquake/database/SeedlinkCommunicator.java index c9b1b2621..d1833af9a 100644 --- a/src/main/java/globalquake/database/SeedlinkCommunicator.java +++ b/src/main/java/globalquake/database/SeedlinkCommunicator.java @@ -37,8 +37,6 @@ public static void runAvailabilityCheck(SeedlinkNetwork seedlinkNetwork, Station parseAvailability(infoString, stationDatabase, seedlinkNetwork); reader.close(); - seedlinkNetwork.getStatus().setString("Done"); - seedlinkNetwork.getStatus().setValue(100); } private static void parseAvailability(String infoString, StationDatabase stationDatabase, SeedlinkNetwork seedlinkNetwork) throws Exception { diff --git a/src/main/java/globalquake/database/StationDatabaseManager.java b/src/main/java/globalquake/database/StationDatabaseManager.java index c949014d7..ec353b54c 100644 --- a/src/main/java/globalquake/database/StationDatabaseManager.java +++ b/src/main/java/globalquake/database/StationDatabaseManager.java @@ -188,6 +188,9 @@ public void runAvailabilityCheck(List toBeUpdated, Runnable onF Future future = executor.submit(task); future.get(SeedlinkCommunicator.SEEDLINK_TIMEOUT_SECONDS, TimeUnit.SECONDS); + seedlinkNetwork.getStatus().setString("Done"); + seedlinkNetwork.getStatus().setValue(100); + break; } catch(TimeoutException e){ seedlinkNetwork.getStatus().setString("Timed out!");