Changeset tag host
: Add domain and path (#689)
* Changeset tag `host`: Add domain and path Extend the value of the changeset tag host key to include the full url of the editor. This way a reader of the changeset can open the editor based on this value. * Remove `path` from changeset tags
This commit is contained in:
parent
4837b2fe14
commit
c88632ce8b
1 changed files with 2 additions and 5 deletions
|
@ -347,13 +347,10 @@ export class ChangesetHandler {
|
|||
const self = this;
|
||||
return new Promise<number>(function (resolve, reject) {
|
||||
|
||||
let path = window.location.pathname;
|
||||
path = path.substr(1, path.lastIndexOf("/"));
|
||||
const metadata = [
|
||||
["created_by", `MapComplete ${Constants.vNumber}`],
|
||||
["locale", Locale.language.data],
|
||||
["host", window.location.host],
|
||||
["path", path],
|
||||
["host", `${window.location.origin}${window.location.pathname}`],
|
||||
["source", self.changes.state["currentUserLocation"]?.features?.data?.length > 0 ? "survey" : undefined],
|
||||
["imagery", self.changes.state["backgroundLayer"]?.data?.id],
|
||||
...changesetTags.map(cstag => [cstag.key, cstag.value])
|
||||
|
@ -408,4 +405,4 @@ export class ChangesetHandler {
|
|||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue