You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@fineract.apache.org by GitBox <gi...@apache.org> on 2019/12/12 19:30:21 UTC

[GitHub] [fineract] mohitsinha commented on a change in pull request #664: FINERACT-802-restrict-client-to-have-single-self-service-user

mohitsinha commented on a change in pull request #664: FINERACT-802-restrict-client-to-have-single-self-service-user
URL: https://github.com/apache/fineract/pull/664#discussion_r357330020
 
 

 ##########
 File path: fineract-provider/src/main/java/org/apache/fineract/useradministration/service/AppUserWritePlatformServiceJpaRepositoryImpl.java
 ##########
 @@ -349,6 +349,10 @@ private void handleDataIntegrityIssues(final JsonCommand command, final Throwabl
                     username);
         }
 
+        if (realCause.getMessage().contains("'unique_self_client'")) {
 
 Review comment:
   I do agree with @vorburger . 
   Correct me if I am wrong.
   The function is called from 4 places in this file and all of them are within a catch block.
   Can you refactor this file a bit, to avoid doing redundant `if-else` as the catch block identifies which type of Exception is there( in a way it is also having that `if-else` logic) ?

----------------------------------------------------------------
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


With regards,
Apache Git Services