File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ public class FileSaver {
1414
1515 public static String saveTodo (Todo todo ) {
1616 char type = 'T' ;
17- String description = todo .description . trim () ;
17+ String description = todo .description ;
1818 int doneStatus = todo .toString ().contains ("[X]" ) ? 1 : 0 ;
1919 String toDoText = type + SEPARATOR + doneStatus
2020 + SEPARATOR + description + System .lineSeparator ();
Original file line number Diff line number Diff line change @@ -15,6 +15,6 @@ public String type() {
1515
1616 @ Override
1717 public String toString () {
18- return type () + super .toString () + "(by:" + by + ")" ;
18+ return type () + super .toString () + " (by:" + by + ")" ;
1919 }
2020}
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ public String type() {
1515 @ Override
1616 public String toString () {
1717 return type () + super .toString ()
18- + "(from: " + from
18+ + " (from: " + from
1919 + " to: " + to + ")" ;
2020 }
2121}
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ public class Task {
55 protected boolean isDone ;
66
77 public Task (String description ) {
8- this .description = description ;
8+ this .description = description . trim () ;
99 this .isDone = false ;
1010 }
1111
@@ -22,6 +22,6 @@ public void markNotDone(){
2222
2323 @ Override
2424 public String toString () {
25- return "[" + getStatusIcon () + "]" + description ;
25+ return "[" + getStatusIcon () + "] " + description ;
2626 }
2727}
You can’t perform that action at this time.
0 commit comments