]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/notes_controller.rb
display an encouragement to contribute after many anonymous notes
[rails.git] / app / controllers / notes_controller.rb
index c47a3abfb9a1e3d605b0fb3e7d92cc072de6fffa..4b4f3d6515f3698370e74d2c92cc96b779b642ac 100644 (file)
@@ -44,5 +44,8 @@ class NotesController < ApplicationController
     render :template => "browse/not_found", :status => :not_found
   end
 
-  def new; end
+  def new
+    @anonymous_notes_count = request.cookies["_osm_anonymous_notes_count"].to_i || 0
+    render :action => :new_readonly if api_status != "online"
+  end
 end