Skip to content

Commit 0320806

Browse files
committed
fix: improve date format error message in ViewAppointmentByDateParser
1 parent 83c6d36 commit 0320806

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/main/java/seedu/address/logic/parser/ViewAppointmentByDateParser.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ public class ViewAppointmentByDateParser implements Parser<ViewAppointmentByDate
2222
public ViewAppointmentByDateCommand parse(String args) throws ParseException {
2323
ArgumentMultimap argMultimap = ArgumentTokenizer.tokenize(args, PREFIX_DATE);
2424

25+
argMultimap.verifyNoDuplicatePrefixesFor(PREFIX_DATE);
26+
2527
if (!arePrefixesPresent(argMultimap, PREFIX_DATE)
2628
|| !argMultimap.getPreamble().isEmpty()) {
2729
throw new ParseException(String.format(MESSAGE_INVALID_COMMAND_FORMAT,

0 commit comments

Comments
 (0)