]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/amf_controller.rb
Eager load node and way details when processing a map call.
[rails.git] / app / controllers / amf_controller.rb
index d88c5ac191fc666475b11aa257be6169c254cfe6..9004397218ddcbc47e2e8a43b5761c6266a35ab8 100644 (file)
@@ -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