1
0
Fork 0
mirror of https://github.com/Luzifer/gpxhydrant.git synced 2024-12-22 12:11:17 +00:00

Fix: Send Changeset and wrap in <osm> element

This commit is contained in:
Knut Ahlers 2016-05-07 14:12:30 +02:00
parent ace7819472
commit 97b39d3c64
Signed by: luzifer
GPG key ID: DC2729FDD34BE99E

View file

@ -191,8 +191,12 @@ func (c *Client) SaveNode(n *Node, cs *Changeset) error {
urlPath = fmt.Sprintf("/node/%d", n.ID)
}
n.Changeset = cs.ID
data := Wrap{Nodes: []*Node{n}}
body := bytes.NewBuffer([]byte{})
if err := xml.NewEncoder(body).Encode(n); err != nil {
if err := xml.NewEncoder(body).Encode(data); err != nil {
return err
}