Skip to content

Invalid input not handled correctly #5

Description

@Jajared

Describe the bug
The add command is not handled correctly when given the wrong input (specifically a partial input)

To Reproduce
Steps to reproduce the behavior:

  1. Run the command 'add n/John Doe p/98765432 e/johnd@example.com a/311, Clementi Ave 2, Clients with duplicate phone numbers allowed to be added #2-25 m/2024-07-12 12:00 t'.
  2. An error message indicating invalid date appears

Expected behavior
Screenshot 2024-04-19 at 4.58.48 PM.png

Originally i wanted to run the command 'add n/John Doe p/98765432 e/johnd@example.com a/311, Clementi Ave 2, #2-25 m/2024-07-12 12:00 t/Friends'.

It is stated in the UG that any extra inputs in the command will not be regarded as part of the command. In this case, it seems like the extra 't' is regarded as part of the date and is thus throwing me a date format error. While this might seem very trivial, there may be instances where users may make a typo or may not complete their command input.

Screenshots
Screenshot 2024-04-19 at 4.54.41 PM.png

Additional context
Nil

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions