gnunet-svn
[Top][All Lists]
Advanced

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

[taler-wallet-core] branch master updated: taler-util: content type head


From: gnunet
Subject: [taler-wallet-core] branch master updated: taler-util: content type header hotfix
Date: Mon, 09 Sep 2024 16:30:51 +0200

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository wallet-core.

The following commit(s) were added to refs/heads/master by this push:
     new 9d1262c75 taler-util: content type header hotfix
9d1262c75 is described below

commit 9d1262c75a98c32100cbd074e62f59fe40c27d55
Author: Florian Dold <florian@dold.me>
AuthorDate: Mon Sep 9 16:30:46 2024 +0200

    taler-util: content type header hotfix
---
 packages/taler-util/src/http-impl.qtart.ts | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/packages/taler-util/src/http-impl.qtart.ts 
b/packages/taler-util/src/http-impl.qtart.ts
index 0993a9566..42a7f41e2 100644
--- a/packages/taler-util/src/http-impl.qtart.ts
+++ b/packages/taler-util/src/http-impl.qtart.ts
@@ -195,7 +195,16 @@ export class HttpLibImpl implements HttpRequestLibrary {
           continue;
         }
         const headerName = headerStr.slice(0, splitPos).trim().toLowerCase();
-        const headerValue = headerStr.slice(splitPos + 1).trim();
+        let headerValue = headerStr.slice(splitPos + 1).trim();
+        // FIXME: This is a hotfix for the broken native networking 
implementation on Android
+        // that sends the content type header value in square brackets
+        if (
+          headerName === "content-type" &&
+          headerValue.startsWith("[") &&
+          headerValue.endsWith("]")
+        ) {
+          headerValue = headerValue.substring(1, headerValue.length - 2);
+        }
         headers.set(headerName, headerValue);
       }
     }

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

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