[gnome-maps/wip/mlundblad/http-useragent: 1/4] osmConnection: Set User-Agent on HTTP session



commit 52a47449d1b3ab1cdac530bc4984847dd49a5978
Author: Marcus Lundblad <ml update uu se>
Date:   Mon Oct 14 22:20:56 2019 +0200

    osmConnection: Set User-Agent on HTTP session

 src/osmConnection.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/src/osmConnection.js b/src/osmConnection.js
index 6b3b7aca..f7842510 100644
--- a/src/osmConnection.js
+++ b/src/osmConnection.js
@@ -47,7 +47,7 @@ const SECRET_SCHEMA = new Secret.Schema("org.gnome.Maps",
 var OSMConnection = class OSMConnection {
 
     constructor() {
-        this._session = new Soup.Session();
+        this._session = new Soup.Session({ user_agent : 'gnome-maps/' + pkg.version });
 
         /* OAuth proxy used for making OSM uploads */
         this._callProxy = Rest.OAuthProxy.new(CONSUMER_KEY, CONSUMER_SECRET,


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