[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] branch master updated: fix loop skip
From: |
gnunet |
Subject: |
[libeufin] branch master updated: fix loop skip |
Date: |
Thu, 14 Jan 2021 19:12:10 +0100 |
This is an automated email from the git hooks/post-receive script.
ms pushed a commit to branch master
in repository libeufin.
The following commit(s) were added to refs/heads/master by this push:
new 47ce51c fix loop skip
47ce51c is described below
commit 47ce51c1be1d10c9427dd2450ae99fa9e66a4136
Author: ms <ms@taler.net>
AuthorDate: Thu Jan 14 19:12:01 2021 +0100
fix loop skip
---
cli/setup-template.sh | 11 +++++------
.../kotlin/tech/libeufin/nexus/bankaccount/BankAccount.kt | 6 ++----
.../main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt | 8 +-------
3 files changed, 8 insertions(+), 17 deletions(-)
diff --git a/cli/setup-template.sh b/cli/setup-template.sh
index 6f42d9f..13b75ec 100755
--- a/cli/setup-template.sh
+++ b/cli/setup-template.sh
@@ -122,12 +122,11 @@ echo Download bank accounts
cat << EOF
-env-setter:
- export NEXUS_BASE_URL=http://localhost:5001/ NEXUS_USERNAME=$NEXUS_USER
NEXUS_PASSWORD=$NEXUS_PASSWORD LIBEUFIN_SANDBOX_URL=$SANDBOX_URL
-
-Connection: $(tput bold)$NEXUS_BANK_CONNECTION_NAME$(tput sgr0)
-Account (imported): $(tput bold)$ACCOUNT_NAME_AT_NEXUS$(tput sgr0)
+Bank connection name: $(tput bold)$NEXUS_BANK_CONNECTION_NAME$(tput sgr0)
+Bank account, imported name: $(tput bold)$ACCOUNT_NAME_AT_NEXUS$(tput sgr0)
+Bank account, native name: $(tput bold)$ACCOUNT_NAME$(tput sgr0)
+env-setter: $(tput bold)export NEXUS_BASE_URL=http://localhost:5001/
NEXUS_USERNAME=$NEXUS_USER NEXUS_PASSWORD=$NEXUS_PASSWORD
LIBEUFIN_SANDBOX_URL=$SANDBOX_URL$(tput sgr0)
EOF
-read -p "Press Enter to terminate the services:"
+read -p "Press Enter to terminate the services: "
diff --git
a/nexus/src/main/kotlin/tech/libeufin/nexus/bankaccount/BankAccount.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/bankaccount/BankAccount.kt
index e46cbcc..019a091 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/bankaccount/BankAccount.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/bankaccount/BankAccount.kt
@@ -126,9 +126,7 @@ fun processCamtMessage(bankAccountId: String, camtDoc:
Document, code: String):
if (acct == null) {
throw NexusError(HttpStatusCode.NotFound, "user not found")
}
- val res = try {
- parseCamtMessage(camtDoc)
- } catch (e: CamtParsingError) {
+ val res = try { parseCamtMessage(camtDoc) } catch (e:
CamtParsingError) {
logger.warn("Invalid CAMT received from bank: $e")
return@transaction false
}
@@ -166,7 +164,7 @@ fun processCamtMessage(bankAccountId: String, camtDoc:
Document, code: String):
logger.info("Found a duplicate: $acctSvcrRef")
// FIXME(dold): See if an old transaction needs to be
superseded by this one
// https://bugs.gnunet.org/view.php?id=6381
- break
+ continue@txloop
}
val rawEntity = NexusBankTransactionEntity.new {
bankAccount = acct
diff --git
a/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
b/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
index ea297a6..541bfde 100644
--- a/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
+++ b/sandbox/src/main/kotlin/tech/libeufin/sandbox/EbicsProtocolBackend.kt
@@ -441,11 +441,7 @@ fun buildCamtString(type: Int, subscriberIban: String,
history: List<RawPayment>
*
* @param type 52 or 53.
*/
-private fun constructCamtResponse(
- type: Int,
- header: EbicsRequest.Header,
- subscriber: EbicsSubscriberEntity
-): MutableList<String> {
+private fun constructCamtResponse(type: Int, header: EbicsRequest.Header,
subscriber: EbicsSubscriberEntity): MutableList<String> {
val dateRange = (header.static.orderDetails?.orderParams as
EbicsRequest.StandardOrderParams).dateRange
val (start: LocalDateTime, end: LocalDateTime) = if (dateRange != null) {
Pair(
@@ -1149,9 +1145,7 @@ private fun makeRequestContext(requestObject:
EbicsRequest): RequestContext {
suspend fun ApplicationCall.ebicsweb() {
val requestDocument = receiveEbicsXml()
-
LOGGER.info("Processing ${requestDocument.documentElement.localName}")
-
when (requestDocument.documentElement.localName) {
"ebicsUnsecuredRequest" -> {
val requestObject =
requestDocument.toObject<EbicsUnsecuredRequest>()
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [libeufin] branch master updated: fix loop skip,
gnunet <=