From 4de6006567ccff573277c9fcfbf9cb3d6bb83a63 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Tue, 28 Apr 2009 15:55:54 +0000 Subject: [PATCH] Eager load nodes and node tags for the way when doing a getway call. --- app/controllers/amf_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/amf_controller.rb b/app/controllers/amf_controller.rb index d88c5ac19..900439721 100644 --- a/app/controllers/amf_controller.rb +++ b/app/controllers/amf_controller.rb @@ -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 -- 2.43.2