Skip to content

Commit

Permalink
Update CommandDelete.java
Browse files Browse the repository at this point in the history
  • Loading branch information
Araavinds authored Nov 8, 2019
1 parent 3729afc commit 866313c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/executor/command/CommandDelete.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public CommandDelete(String userInput) {
@Override
public void execute(StorageManager storageManager) {
String outputStr;
int index = Integer.parseInt(userInput.replace("delete", "").trim()) - 1;
try {
int index = Integer.parseInt(userInput.replace("delete", "").trim()) - 1;
outputStr = ("Task '"
+ (index + 1)
+ ") "
Expand All @@ -37,4 +37,4 @@ public void execute(StorageManager storageManager) {
this.infoCapsule.setCodeToast();
this.infoCapsule.setOutputStr(outputStr);
}
}
}

0 comments on commit 866313c

Please sign in to comment.