Skip to content

Conversation

@omupenguin
Copy link

@omupenguin omupenguin commented Sep 12, 2019

Copy link

@andyrobert3 andyrobert3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good progress so far, the team has written significant amount of features
These are the pointers that I saw:

  1. Enums can be used, especially for Task type
  2. Commented code should be removed to improve readability
  3. Catch blocks should handle exceptions in a meaningful manner - https://stackify.com/best-practices-exceptions-java/ for tips on how to handle exceptions.

String modeToModify = mode.split(" ")[1];
if (modeToModify.equals("entry")) {
if (verifyAddCommand() == true) {
return new ModifyEntryCommand(inputArray[1], stringToDouble(inputArray[2]), inputArray[3], date);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1, 2, 3 index are magic numbers that can be replaced with variables

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you provide an example regarding this?

* Checks if the first word after 'add' is either 'income' or 'expense'.
* @param s String to be analysed.
* @return Either 'expense' or 'income' if either are passed in.
* @throws Exception ???

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

may want to specify exception type & details on it

@omupenguin
Copy link
Author

PR was not tracked last week even though it was created a while back.

nishanthelango added a commit to nishanthelango/Duchess that referenced this pull request Nov 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants