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 2020/11/03 13:29:46 UTC

[GitHub] [fineract] vorburger commented on a change in pull request #1486: Bump ancient OkHTTP & Retrofit in Hooks (FINERACT-1252)

vorburger commented on a change in pull request #1486:
URL: https://github.com/apache/fineract/pull/1486#discussion_r516484425



##########
File path: fineract-provider/src/main/java/org/apache/fineract/infrastructure/hooks/service/HookWritePlatformServiceJpaRepositoryImpl.java
##########
@@ -282,15 +282,10 @@ private void validateHookRules(final HookTemplate template, final Set<HookConfig
             if (conf.getFieldName().equals(payloadURLName)) {
                 try {
                     final WebHookService service = processorHelper.createWebHookService(fieldValue);
-                    service.sendEmptyRequest();
-                } catch (RetrofitError re) {
-                    // Swallow error if it's because of method not supported or
-                    // if url throws 404 - required for integration test,
-                    // url generated on 1st POST request
-                    if (re.getResponse() == null) {
-                        String errorMessage = "url.invalid";
-                        baseDataValidator.reset().failWithCodeNoParameterAddedToErrorCode(errorMessage);
-                    }
+                    service.sendEmptyRequest().execute();
+                } catch (IOException re) {
+                    String errorMessage = "url.invalid";

Review comment:
       I was also wondering, but the integration tests all still pass now, so looks like this actually wasn't needed.




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