X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/b5f06e06c14f440d3c014b348149fe9ec1b67657..59ac72b2137cbe8bf7333948b641e6e339de3bb1:/app/controllers/api/notes_controller.rb diff --git a/app/controllers/api/notes_controller.rb b/app/controllers/api/notes_controller.rb index 8a41d5db8..c152c6272 100644 --- a/app/controllers/api/notes_controller.rb +++ b/app/controllers/api/notes_controller.rb @@ -1,14 +1,15 @@ module Api class NotesController < ApiController before_action :check_api_readable - before_action :setup_user_auth, :only => [:create, :comment, :show] + before_action :check_api_writable, :only => [:create, :comment, :close, :reopen, :destroy] + before_action :setup_user_auth, :only => [:create, :show] before_action :authorize, :only => [:close, :reopen, :destroy, :comment] authorize_resource - before_action :check_api_writable, :only => [:create, :comment, :close, :reopen, :destroy] before_action :set_locale around_action :api_call_handle_error, :api_call_timeout + before_action :set_request_formats, :except => [:feed] ## # Return a list of notes in a given area