diff --git a/app/src/main/java/de/jotomo/ruffyscripter/commands/BolusCommand.java b/app/src/main/java/de/jotomo/ruffyscripter/commands/BolusCommand.java index edc8b3abe5..d5197452e3 100644 --- a/app/src/main/java/de/jotomo/ruffyscripter/commands/BolusCommand.java +++ b/app/src/main/java/de/jotomo/ruffyscripter/commands/BolusCommand.java @@ -81,7 +81,7 @@ public class BolusCommand implements Command { if (!scripter.currentMenu.attributes().contains(MenuAttribute.BOLUS)) { throw new CommandException().success(false).enacted(true) - .message("Bolus was delivered, but enable to confirm it with history record"); + .message("Bolus was delivered, but unable to confirm it with history record"); } double lastBolusInHistory = (double) scripter.currentMenu.getAttribute(MenuAttribute.BOLUS); diff --git a/app/src/main/java/de/jotomo/ruffyscripter/commands/SetTbrCommand.java b/app/src/main/java/de/jotomo/ruffyscripter/commands/SetTbrCommand.java index fe4ad3c65a..4ffd154acf 100644 --- a/app/src/main/java/de/jotomo/ruffyscripter/commands/SetTbrCommand.java +++ b/app/src/main/java/de/jotomo/ruffyscripter/commands/SetTbrCommand.java @@ -234,14 +234,14 @@ public class SetTbrCommand implements Command { // A "TBR CANCELLED alert" is only raised by the pump when the remaining time is // greater than 60s (displayed as 0:01, the pump goes from there to finished. // We could read the remaining duration from MAIN_MENU, but by the time we're here, - // the pmup could have moved from 0:02 to 0:01, so instead, check if a "TBR CANCELLED alert" + // the pumup could have moved from 0:02 to 0:01, so instead, check if a "TBR CANCELLED" alert // is raised and if so dismiss it - long inTwoSeconds = System.currentTimeMillis() + 5 * 1000; + long inFiveSeconds = System.currentTimeMillis() + 5 * 1000; boolean alertProcessed = false; - while (System.currentTimeMillis() < inTwoSeconds && !alertProcessed) { + while (System.currentTimeMillis() < inFiveSeconds && !alertProcessed) { if (scripter.currentMenu.getType() == MenuType.WARNING_OR_ERROR) { - // Check the raised alarm is TBR CANCELLED, so we're not accidentally cancelled - // a different that might be raised at the same time. + // Check the raised alarm is TBR CANCELLED, so we're not accidentally cancelling + // a different alarm that might be raised at the same time. // Note that the message is permanently displayed, while the error code is blinking. // A wait till the error code can be read results in the code hanging, despite // menu updates coming in, so just check the message. @@ -252,10 +252,10 @@ public class SetTbrCommand implements Command { .message("An alert other than the expected TBR CANCELLED was raised by the pump: " + errorMsg + ". Please check the pump."); } - // confirm "TBR CANCELLED alert" + // confirm "TBR CANCELLED" alert scripter.verifyMenuIsDisplayed(MenuType.WARNING_OR_ERROR); scripter.pressCheckKey(); - // dismiss "TBR CANCELLED alert" + // dismiss "TBR CANCELLED" alert scripter.verifyMenuIsDisplayed(MenuType.WARNING_OR_ERROR); scripter.pressCheckKey(); scripter.waitForMenuToBeLeft(MenuType.WARNING_OR_ERROR);