Skip to content

Commit

Permalink
Include brackets in toString
Browse files Browse the repository at this point in the history
  • Loading branch information
Anant1902 committed Apr 10, 2024
1 parent 33356b9 commit 2933d59
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions src/main/java/seedu/address/model/weeknumber/WeekNumber.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,6 @@ public WeekNumber(String weekNumber) {
public static boolean isValidWeekNumber(String test) {
return test.matches(VALIDATION_REGEX);
}

@Override
public String toString() {
return value.toString();
}

@Override
public boolean equals(Object other) {
if (other == this) {
Expand All @@ -55,4 +49,8 @@ public boolean equals(Object other) {
public int hashCode() {
return value.hashCode();
}
@Override
public String toString() {
return "[" + value.toString() + "]";
}
}

0 comments on commit 2933d59

Please sign in to comment.