1
0
Fork 0
mirror of https://github.com/Luzifer/gpxhydrant.git synced 2024-12-23 04:31:18 +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) urlPath = fmt.Sprintf("/node/%d", n.ID)
} }
n.Changeset = cs.ID
data := Wrap{Nodes: []*Node{n}}
body := bytes.NewBuffer([]byte{}) body := bytes.NewBuffer([]byte{})
if err := xml.NewEncoder(body).Encode(n); err != nil { if err := xml.NewEncoder(body).Encode(data); err != nil {
return err return err
} }