thesmallstar commented on pull request #1238: URL: https://github.com/apache/fineract/pull/1238#issuecomment-670168858
Take this code for example: https://github.com/apache/fineract/blob/2323450e71d1508e6ff218d48b856aefa04542d0/fineract-provider/src/main/java/org/apache/fineract/accounting/journalentry/service/JournalEntryRunningBalanceUpdateServiceImpl.java#L243-L269 here, it wants us to add a default statement and from what I have understood from https://github.com/apache/fineract/pull/1006#issuecomment-641687223 by @ptuomola that 1. If we are adding new value to the enum, error-prone directly asks us to cover that in the switch case. 2. If there is no common way to handle things there is no need for a default statement. In other words, in all of these cases all the values that are covered by the enum are always included thanks to error-prone, and also we don't have any common way of handling things, that means we would end up adding an incorrect/blank default statement that brings no benefit. would you agree on this? @vorburger @ptuomola @percyashu ? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
