Add host, locale, user_agent to changeset tags (closes #2449)

This commit is contained in:
Bryan Housel
2015-03-19 14:29:27 -04:00
parent ace428ce41
commit fbed61fa1e

View File

@@ -242,12 +242,15 @@ iD.Connection = function() {
connection.changesetTags = function(comment, imageryUsed) {
var tags = {
created_by: 'iD ' + iD.version,
host: (window.location.origin + window.location.pathname).substr(0, 255),
locale: iD.detect().locale,
user_agent: navigator.userAgent.substr(0, 255),
imagery_used: imageryUsed.join(';').substr(0, 255),
created_by: 'iD ' + iD.version
};
if (comment) {
tags.comment = comment;
tags.comment = comment.substr(0, 255);
}
return tags;