Skip to content

Commit

Permalink
Avoid vcat-splatting (#51)
Browse files Browse the repository at this point in the history
thanks. I also added another answer to this SO posts.
blegat authored Aug 29, 2021

Verified

This commit was signed with the committer’s verified signature.
Kikobeats Kiko Beats
1 parent fc056ff commit 4241659
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/google_routing.jl
Original file line number Diff line number Diff line change
@@ -98,15 +98,15 @@ Extract route from Google API results
"""
function extract_google_route(routes::Dict)
res = Array{Tuple{Float64,Float64},1}[]
res = Tuple{Float64,Float64}[]
legs = routes["legs"]
for leg in legs
steps = leg["steps"]
for step in steps
push!(res,OpenStreetMapX.decode(step["polyline"]["points"]))
append!(res, OpenStreetMapX.decode(step["polyline"]["points"]))
end
end
return vcat(res...)
return res
end

"""

0 comments on commit 4241659

Please sign in to comment.