class Xs2aUpdatePaymentAfterSpiService {

    public boolean updatePaymentStatus(@NotNull String paymentId, @NotNull TransactionStatus status) {
        CmsResponse<Boolean> response = updatePaymentStatusAfterSpiService.updatePaymentStatus(paymentId, status);
        boolean statusUpdated = response.isSuccessful() && response.getPayload();

        if (statusUpdated) {
            loggingContextService.storeTransactionStatus(status);
        }

        return statusUpdated;
    }

}