before_action :authorize_web
before_action :set_locale
- before_action -> { check_database_readable(true) }
+ before_action -> { check_database_readable(:need_api => true) }
before_action :require_oauth
+ before_action :update_totp, :only => [:query]
around_action :web_timeout
authorize_resource :class => false
render :action => "not_found", :status => :not_found
end
- def note
- @type = "note"
-
- if current_user&.moderator?
- @note = Note.find(params[:id])
- @note_comments = @note.comments.unscope(:where => :visible)
- else
- @note = Note.visible.find(params[:id])
- @note_comments = @note.comments
- end
- rescue ActiveRecord::RecordNotFound
- render :action => "not_found", :status => :not_found
- end
+ def query; end
end