Open lixupengg opened 4 years ago
Looking at the UG or the error message more carefully, the first error message is like that because it is specified that a valid delete-d command should have the index being a positive integer. SInce 0 is not a positive integer, "delete-d 0" is an invalid command, so an error is thrown stating the command is invalid.
Only when the command is valid (index is positive), then we proceed to look at whether the user gave a index that is too large. Only if the command is already valid, we give the error specific to index instead of an invalid command error.
Thanks for pointing out!
Team chose [response.Rejected
]
Reason for disagreement: This error was raised as the wrong error message is being thrown for "add-d" command, but the justification is talking about the "delete-d" command. Thus, no reason was cited as to why this error should be rejected.
Wrong error message being thrown. Error raised should be invalid expense index (which is thrown when you add-d 500 d/boohoo), but the error raised now even though index is still invalid is wrong command format.