gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[libeufin] branch master updated: reduce newlines


From: gnunet
Subject: [libeufin] branch master updated: reduce newlines
Date: Wed, 29 Jan 2020 16:47:17 +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 b266d4a  reduce newlines
b266d4a is described below

commit b266d4af26f1b3c47be4dc251aac0d87c7bc4b9e
Author: Marcello Stanisci <address@hidden>
AuthorDate: Wed Jan 29 16:47:10 2020 +0100

    reduce newlines
---
 nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt | 19 -------------------
 sandbox/src/main/python/libeufin-cli              |  6 ------
 2 files changed, 25 deletions(-)

diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt 
b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
index 8c61bf1..61c0df1 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
@@ -186,13 +186,11 @@ fun main() {
                 return@intercept finish()
             }
         }
-
         routing {
             get("/") {
                 call.respondText("Hello by Nexus!\n")
                 return@get
             }
-
             post("/ebics/subscribers/{id}/sendC52") {
                 val id = expectId(call.parameters["id"])
                 val body = call.receive<EbicsDateRange>()
@@ -210,7 +208,6 @@ fun main() {
                         )
                     )
                 }
-
                 val response = client.postToBankSigned<EbicsRequest, 
EbicsResponse>(
                     subscriberData.ebicsUrl,
                     createDownloadInitializationPhase(
@@ -223,13 +220,11 @@ fun main() {
                     ),
                     subscriberData.customerAuthPriv
                 )
-
                 val payload: ByteArray =
                     decryptAndDecompressResponse(
                         response.value,
                         subscriberData.customerEncPriv
                     )
-
                 call.respondText(
                     payload.toString(Charsets.UTF_8),
                     ContentType.Text.Plain,
@@ -258,13 +253,10 @@ fun main() {
                     ),
                     subscriberData.customerAuthPriv
                 )
-
                 logger.debug("HTD response: " + 
XMLUtil.convertJaxbToString<EbicsResponse>(response.value))
-
                 if (response.value.body.returnCode.value != "000000") {
                     throw EbicsError(response.value.body.returnCode.value)
                 }
-
                 val er = CryptoUtil.EncryptionResult(
                     
response.value.body.dataTransfer!!.dataEncryptionInfo!!.transactionKey,
                     (response.value.body.dataTransfer!!.dataEncryptionInfo as 
EbicsTypes.DataEncryptionInfo)
@@ -277,17 +269,13 @@ fun main() {
                     subscriberData.customerEncPriv
                 )
                 val data = 
EbicsOrderUtil.decodeOrderDataXml<HTDResponseOrderData>(dataCompr)
-
-
                 logger.debug("HTD payload is: 
${XMLUtil.convertJaxbToString(data)}")
-
                 val ackRequest = EbicsRequest.createForDownloadReceiptPhase(
                     response.value.header._static.transactionID ?: throw 
BankInvalidResponse(
                         HttpStatusCode.ExpectationFailed
                     ),
                     subscriberData.hostId
                 )
-
                 val ackResponse = 
client.postToBankSignedAndVerify<EbicsRequest, EbicsResponse>(
                     subscriberData.ebicsUrl,
                     ackRequest,
@@ -296,20 +284,16 @@ fun main() {
                     ),
                     subscriberData.customerAuthPriv
                 )
-
                 logger.debug("HTD final response: " + 
XMLUtil.convertJaxbToString<EbicsResponse>(response.value))
-
                 if (ackResponse.value.body.returnCode.value != "000000") {
                     throw EbicsError(response.value.body.returnCode.value)
                 }
-
                 call.respondText(
                     "Success! Details (temporarily) reported on the Nexus 
console.",
                     ContentType.Text.Plain,
                     HttpStatusCode.OK
                 )
             }
-
             get("/ebics/subscribers/{id}/keyletter") {
                 val id = expectId(call.parameters["id"])
                 var usernameLine = "TODO"
@@ -452,7 +436,6 @@ fun main() {
                 call.respond(ret)
                 return@get
             }
-
             get("/ebics/subscribers/{id}") {
                 val id = expectId(call.parameters["id"])
                 val response = transaction {
@@ -766,7 +749,6 @@ fun main() {
                 call.respondText("Bank keys stored in database\n", 
ContentType.Text.Plain, HttpStatusCode.OK)
                 return@post
             }
-
             post("/ebics/subscribers/{id}/sendHia") {
                 val id = expectId(call.parameters["id"])
                 val subscriberData = transaction {
@@ -799,7 +781,6 @@ fun main() {
             }
         }
     }
-
     logger.info("Up and running")
     server.start(wait = true)
 }
diff --git a/sandbox/src/main/python/libeufin-cli 
b/sandbox/src/main/python/libeufin-cli
index 833f7c7..70eb105 100755
--- a/sandbox/src/main/python/libeufin-cli
+++ b/sandbox/src/main/python/libeufin-cli
@@ -295,12 +295,10 @@ def prepare(ctx, account_id, nexus_base_url):
   "nexus-base-url"
 )
 def htd(ctx, account_id, prepare, nexus_base_url):
-
     if prepare:
         ctx.invoke(ini)
         ctx.invoke(hia)
         ctx.invoke(sync)
-
     url = urljoin(nexus_base_url, 
"/ebics/subscribers/{}/sendHtd".format(account_id))
     try:
         resp = get(url)
@@ -321,14 +319,12 @@ def htd(ctx, account_id, prepare, nexus_base_url):
   "nexus-base-url"
 )
 def hia(obj, account_id, nexus_base_url):
-    
     url = urljoin(nexus_base_url, 
"/ebics/subscribers/{}/sendHia".format(account_id))
     try:
         resp = post(url)
     except Exception:
         print("Could not reach the bank")
         return
-
     print(resp.content.decode("utf-8"))
 
 @ebics.command(help="Send HPB message")
@@ -412,10 +408,8 @@ def new_subscriber(obj, account_id, user_id, partner_id, 
system_id, host_id, ebi
             partnerID=partner_id,
             hostID=host_id
     )
-
     if system_id:
         body.update(system_id)
-
     try:
         resp = post(nexus_url, json=body)
     except Exception:

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]