[gnome-maps/wip/osm-edit] osmEdit: Remove left-over debug output
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-maps/wip/osm-edit] osmEdit: Remove left-over debug output
- Date: Tue, 8 Dec 2015 21:25:39 +0000 (UTC)
commit a47fe5cd3a34f9b09d9a95cdda4436c70b85a0ed
Author: Marcus Lundblad <ml update uu se>
Date: Tue Dec 8 22:24:39 2015 +0100
osmEdit: Remove left-over debug output
https://bugzilla.gnome.org/show_bug.cgi?id=72662
src/osmConnection.js | 34 +++-------------------------------
1 files changed, 3 insertions(+), 31 deletions(-)
---
diff --git a/src/osmConnection.js b/src/osmConnection.js
index 7d92337..b1da05d 100644
--- a/src/osmConnection.js
+++ b/src/osmConnection.js
@@ -75,8 +75,6 @@ const OSMConnection = new Lang.Class({
return;
}
- Utils.debug ('data received: ' + message.response_body.data);
-
try {
let object = Maps.osm_parse (message.response_body.data,
message.response_body.length);
@@ -128,8 +126,6 @@ const OSMConnection = new Lang.Class({
Maps.OSMChangeset.new(comment, 'gnome-maps ' + pkg.version);
let xml = changeset.serialize();
- Utils.debug('about open changeset:\n' + xml + '\n');
-
let call = Maps.OSMOAuthProxyCall.new(this._callProxy, xml);
call.set_method('PUT');
call.set_function('/changeset/create');
@@ -140,8 +136,6 @@ const OSMConnection = new Lang.Class({
},
_onChangesetOpened: function(call, callback) {
- Utils.debug('status: ' + call.get_status_code());
-
if (call.get_status_code() !== Soup.Status.OK) {
callback(false, call.get_status_code(), null);
return;
@@ -149,8 +143,6 @@ const OSMConnection = new Lang.Class({
let changesetId = parseInt(call.get_payload());
- Utils.debug('opened changeset: ' + changesetId);
-
callback(true, call.get_status_code(), changesetId);
},
@@ -158,10 +150,8 @@ const OSMConnection = new Lang.Class({
object.changeset = changeset;
let xml = object.serialize();
-
- Utils.debug('about to upload object:\n' + xml + '\n');
-
let call = Maps.OSMOAuthProxyCall.new(this._callProxy, xml);
+
call.set_method('PUT');
call.set_function(this._getCreateOrUpdateFunction(object, type));
@@ -181,11 +171,10 @@ const OSMConnection = new Lang.Class({
deleteObject: function(object, type, changeset, callback) {
object.changeset = changeset;
- let xml = object.serialize();
-
- Utils.debug('about to delete object:\n' + xml + '\n');
+ let xml = object.serialize();
let call = Maps.OSMOAuthProxyCall.new(this._callProxy, xml);
+
call.set_method('DELETE');
call.set_function(this._getDeleteFunction(object, type));
@@ -246,16 +235,10 @@ const OSMConnection = new Lang.Class({
},
_onRequestOAuthToken: function(error, callback) {
- Utils.debug('OAuth request token callback');
- Utils.debug('callback: ' + callback);
-
if (error) {
- Utils.debug('error message: ' + error.message);
callback(false);
}
- Utils.debug('request token: ' + this._oauthProxy.get_token());
- Utils.debug('request secret: ' + this._oauthProxy.get_token_secret());
this._oauthToken = this._oauthProxy.get_token();
this._oauthTokenSecret = this._oauthProxy.get_token_secret();
callback(true);
@@ -267,18 +250,13 @@ const OSMConnection = new Lang.Class({
let uri = new Soup.URI(loginUrl);
let msg = new Soup.Message({method: 'GET', uri: uri});
- Utils.debug('calling login form URL: ' + loginUrl);
-
this._session.queue_message(msg, (function(obj, message) {
this._onLoginFormReceived(message, username, password, callback);
}).bind(this));
},
_onLoginFormReceived: function(message, username, password, callback) {
- Utils.debug('status: ' + message.status_code);
-
if (message.status_code !== Soup.Status.OK) {
- Utils.debug('Failed to load login form');
callback(false);
return;
}
@@ -287,11 +265,8 @@ const OSMConnection = new Lang.Class({
this._extractOSMSessionID(message.response_headers);
let osmSessionToken =
this._extractToken(message.response_body.data);
- Utils.debug('session ID: ' + osmSessionID);
- Utils.debug('session token: ' + osmSessionToken);
if (osmSessionID === null || osmSessionToken === null) {
- Utils.debug('Failed to extract OSM session');
callback(false, null);
return;
}
@@ -381,7 +356,6 @@ const OSMConnection = new Lang.Class({
_onAccessOAuthToken: function(error, callback) {
if (error) {
- Utils.debug('error message: ' + error.message);
callback(false);
return;
}
@@ -426,8 +400,6 @@ const OSMConnection = new Lang.Class({
_extractOSMSessionID: function(responseHeaders) {
let cookie = responseHeaders.get('Set-Cookie');
- Utils.debug('cookie: ' + cookie);
-
if (cookie === null)
return null;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]