Skip to content

Commit

Permalink
little changes
Browse files Browse the repository at this point in the history
  • Loading branch information
XunyiiZ committed Mar 21, 2022
1 parent eb819e8 commit a258d97
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 20 deletions.
4 changes: 0 additions & 4 deletions data/task-file

This file was deleted.

32 changes: 16 additions & 16 deletions src/main/java/controller/Duke.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,23 +27,23 @@ public Duke(String filePath) {
}


public void run() {
ui.showWelcome();
boolean isExit = false;
while (!isExit) {
try {
String fullCommand = ui.readCommand();
ui.showLine(); // show the divider line ("_______")
Command c = Parser.parse(fullCommand); // make parse as static method !!!
c.execute(tasks, ui, storage);
isExit = c.isExit();
} catch (DukeException e) {
ui.showError(e.getErrorMessage());
} finally {
ui.showLine();
}
public void run() {
ui.showWelcome();
boolean isExit = false;
while (!isExit) {
try {
String fullCommand = ui.readCommand();
ui.showLine(); // show the divider line ("_______")
Command c = Parser.parse(fullCommand); // make parse as static method !!!
c.execute(tasks, ui, storage);
isExit = c.isExit();
} catch (DukeException e) {
ui.showError(e.getErrorMessage());
} finally {
ui.showLine();
}
return;
}
return;
}


Expand Down

0 comments on commit a258d97

Please sign in to comment.