class DecoupledAisAuthorizationService implements AisAuthorizationService {

    @Override
    public AuthorisationProcessorResponse updateConsentPsuData(UpdateAuthorisationRequest request, AuthorisationProcessorResponse response) {
        if (response.hasError()) {
            log.info("Consent-ID [{}], Authentication-ID [{}], PSU-ID [{}]. Update consent authorisation has failed. Error msg: {}.",
                     request.getBusinessObjectId(), request.getAuthorisationId(), request.getPsuData().getPsuId(), response.getErrorHolder());
        } else {
            aisConsentService.updateConsentAuthorisation(aisConsentMapper.mapToUpdateConsentPsuDataReq(request, response));
        }

        return response;
    }

}