]> git.openstreetmap.org Git - rails.git/commitdiff
unbreak undelete
authorRichard Fairhurst <richard@systemed.net>
Wed, 6 Feb 2008 22:43:14 +0000 (22:43 +0000)
committerRichard Fairhurst <richard@systemed.net>
Wed, 6 Feb 2008 22:43:14 +0000 (22:43 +0000)
app/controllers/amf_controller.rb

index ac0809219ad4ee1c23e076914efb8b04b52916ea..11594c436d25f0ba112f7939c9268bb4158f5daf 100644 (file)
@@ -560,7 +560,7 @@ class AmfController < ApplicationController
 
   # Get the latest version id of a way
   def getlastversion(id,version) #:doc:
-    old_way = OldWay.find(:first, :conditions => ['id = ?' , id], :order => 'version DESC')
+    old_way = OldWay.find(:first, :conditions => ['visible=1 AND id=?' , id], :order => 'version DESC')
     old_way.version
   end