[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] branch master updated: checks
From: |
gnunet |
Subject: |
[libeufin] branch master updated: checks |
Date: |
Wed, 18 Mar 2020 16:54:53 +0100 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a commit to branch master
in repository libeufin.
The following commit(s) were added to refs/heads/master by this push:
new d09e529 checks
d09e529 is described below
commit d09e529630a321c3f21ff0f8dab0a467c21dcf2c
Author: Marcello Stanisci <address@hidden>
AuthorDate: Wed Mar 18 16:54:47 2020 +0100
checks
---
nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
index c474af6..9e99ce1 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
@@ -469,8 +469,12 @@ fun main() {
val subscriberId = expectId(call.parameters["id"])
transaction {
- val accountinfo = EbicsAccountInfoEntity.findById(acctid)
- val subscriber =
EbicsSubscriberEntity.findById(subscriberId)
+ val accountinfo = EbicsAccountInfoEntity.findById(acctid)
?: throw NexusError(
+ HttpStatusCode.NotFound, "Bank account with id
'$acctid' not found (trigger HTD first?)"
+ )
+ val subscriber =
EbicsSubscriberEntity.findById(subscriberId) ?: throw NexusError(
+ HttpStatusCode.NotFound, "Subscriber '$subscriberId'
not found"
+ )
if (accountinfo?.subscriber != subscriber) {
throw NexusError(HttpStatusCode.BadRequest, "Claimed
bank account '$acctid' doesn't belong to subscriber '$subscriberId'!")
}
--
To stop receiving notification emails like this one, please contact
address@hidden.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [libeufin] branch master updated: checks,
gnunet <=