Eager load nodes and node tags for the way when doing a getway call.
This commit is contained in:
parent
bcbbf1944b
commit
4de6006567
1 changed files with 1 additions and 1 deletions
|
@ -266,7 +266,7 @@ class AmfController < ApplicationController
|
|||
# then rails only seems to return the first copy of a node when a
|
||||
# way includes a node more than once
|
||||
begin
|
||||
way = Way.find(wayid)
|
||||
way = Way.find(wayid, :include => { :nodes => :node_tags })
|
||||
rescue ActiveRecord::RecordNotFound
|
||||
return [wayid,[],{}]
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue