diff --git a/src/main/java/logic/Parser.java b/src/main/java/logic/Parser.java
index e4167e626d..c42fef6a9c 100644
--- a/src/main/java/logic/Parser.java
+++ b/src/main/java/logic/Parser.java
@@ -232,7 +232,14 @@ private static Command parseTaskLog(String userInput) throws FarmioException {
             return new CommandLog(pageNumber);
         }
         LOGGER.log(Level.INFO, "Detected invalid command for command: " + userInput);
-        throw new FarmioException("Invalid Log Page \nPlease enter log PAGE_NUMBER.");
+        try {
+            if (!userInput.substring(0, userInput.indexOf(" ")).equals("log")) {
+                throw new FarmioException("Invalid command!");
+            }
+        } catch (IndexOutOfBoundsException e) {
+            throw new FarmioException("Invalid command!");
+        }
+        throw new FarmioException("Invalid Log Page! Please enter log PAGE_NUMBER");
     }
 
     /**
diff --git a/src/main/java/logic/usercode/actions/GotoMarketAction.java b/src/main/java/logic/usercode/actions/GotoMarketAction.java
index 69b8724dbc..1a7ff5d40b 100644
--- a/src/main/java/logic/usercode/actions/GotoMarketAction.java
+++ b/src/main/java/logic/usercode/actions/GotoMarketAction.java
@@ -14,7 +14,7 @@ public GotoMarketAction() {
     @Override
     public void execute(Frontend frontend, Storage storage, Farmer farmer) throws FarmioFatalException {
         if (farmer.getLocation().equals("Market")) {
-            frontend.simulate("GotoMarketSimulation", 12);
+            frontend.simulate("GotoMarketSimulation", 1);
             frontend.typeWriter("You are already at the market", false);
         } else {
             farmer.changeLocation("Traveling");