fineract-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [fineract] ptuomola commented on a change in pull request #1022: FINERACT-822 enable UnnecessaryDefaultInEnumSwitch error
Date Sun, 14 Jun 2020 18:31:32 GMT

ptuomola commented on a change in pull request #1022:
URL: https://github.com/apache/fineract/pull/1022#discussion_r439856100



##########
File path: fineract-provider/src/main/java/org/apache/fineract/infrastructure/documentmanagement/contentrepository/ContentRepositoryUtils.java
##########
@@ -55,9 +55,8 @@ public static ImageMIMEtype fromFileExtension(ImageFileExtension fileExtension)
                     return ImageMIMEtype.JPEG;
                 case PNG:
                     return ImageMIMEtype.PNG;
-                default:
-                    throw new IllegalArgumentException();
             }
+            throw new IllegalArgumentException();

Review comment:
       Same here - shouldn't we just remove the default case altogether, not add anything
back? 




----------------------------------------------------------------
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:
users@infra.apache.org



Mime
View raw message