Skip to content

Commit

Permalink
remove go vet warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
olt committed Nov 13, 2013
1 parent 9e0fd75 commit 2d1c980
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 7 deletions.
1 change: 0 additions & 1 deletion geom/geojson/geojson.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,6 @@ func constructPolygons(obj *object) ([]polygon, error) {
default:
return nil, errors.New("unknown type: " + obj.Type)
}
return nil, nil
}

type GeoJson struct {
Expand Down
8 changes: 4 additions & 4 deletions geom/limit/limit.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ func tileBounds(bounds geos.Bounds, width float64) []geos.Bounds {
for x := 0; x < int(xSteps); x++ {
for y := 0; y < int(ySteps); y++ {
results = append(results, geos.Bounds{
minX + float64(x)*width,
minY + float64(y)*width,
minX + float64(x+1)*width,
minY + float64(y+1)*width,
MinX: minX + float64(x)*width,
MinY: minY + float64(y)*width,
MaxX: minX + float64(x+1)*width,
MaxY: minY + float64(y+1)*width,
})
}
}
Expand Down
2 changes: 1 addition & 1 deletion writer/relations.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ NextRel:
for _, g := range parts {
rel := element.Relation(*r)
rel.Id = -r.Id
rel.Geom = &element.Geometry{g, geos.AsEwkbHex(g)}
rel.Geom = &element.Geometry{Geom: g, Wkb: geos.AsEwkbHex(g)}
rw.inserter.InsertPolygon(rel.OSMElem, matches)
}
} else {
Expand Down
2 changes: 1 addition & 1 deletion writer/ways.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ func (ww *WayWriter) buildAndInsert(g *geos.Geos, w *element.Way, matches interf
}
for _, p := range parts {
way := element.Way(*w)
way.Geom = &element.Geometry{p, g.AsEwkbHex(p)}
way.Geom = &element.Geometry{Geom: p, Wkb: g.AsEwkbHex(p)}
if isPolygon {
ww.inserter.InsertPolygon(way.OSMElem, matches)
} else {
Expand Down

0 comments on commit 2d1c980

Please sign in to comment.