[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] branch master updated: Fix response status code.
From: |
gnunet |
Subject: |
[libeufin] branch master updated: Fix response status code. |
Date: |
Fri, 06 Jan 2023 17:26:21 +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 dcc9d141 Fix response status code.
dcc9d141 is described below
commit dcc9d141fa47be6aceeffb23b95a4a0ae3914c01
Author: MS <ms@taler.net>
AuthorDate: Fri Jan 6 17:24:48 2023 +0100
Fix response status code.
Responding 204 when the array of incoming
transactions from the Taler Wire Gateway API
is empty.
---
nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
index 264d092e..2929eca5 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/Taler.kt
@@ -468,7 +468,14 @@ private suspend fun historyIncoming(call: ApplicationCall)
{
}
}
}
- return call.respond(TextContent(customConverter(history),
ContentType.Application.Json))
+ val responseCode = if (history.incoming_transactions.size == 0)
+ HttpStatusCode.NoContent else
+ HttpStatusCode.OK
+ return call.respond(
+ status = responseCode,
+ TextContent(customConverter(history),
+ ContentType.Application.Json)
+ )
}
/**
--
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 response status code.,
gnunet <=