Skip to content

Commit 6d51f6e

Browse files
author
fuyixuan
committed
correct some bugs
1 parent 924064e commit 6d51f6e

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

data/Sirius.txt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
T | 0 | asd
22
D | 1 | 123 | today
3-
E | 1 | asdasd | 3 | 6pm
4-
T | 0 | asdasds
3+
E | 0 | asdasd | 3 | 6pm
4+
T | 0 | asd
5+
T | 0 | asd

src/main/Sirius.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,6 @@ public static void addTask(String[] commandPieces, ArrayList<Task> list){
8888
System.out.println("Got it. I've added this task:");
8989
System.out.println(list.get(list.size()-1).toString());
9090
System.out.println("Now you have " + list.size() + " tasks in the list.");
91-
System.out.println(list.get(list.size()-1).toString());
92-
System.out.println("Now you have " + list.size() + " tasks in the list.");
9391
System.out.println(SEPARATOR);
9492
}
9593
public static void deleteTask(String[] commandPieces, ArrayList<Task> list){
@@ -280,7 +278,8 @@ public static void main(String[] args) {
280278
saveTaskList(list);
281279
break;
282280
default:
283-
throw new IllegalCommandException("I don't understand it. Please enter an illegal command!");
281+
System.out.println(SEPARATOR);
282+
throw new IllegalCommandException("I don't understand it. Please enter an illegal command!" + "\n" + SEPARATOR);
284283
}
285284
} catch(IllegalCommandException e){
286285
System.out.println(e.getMessage());

0 commit comments

Comments
 (0)