Commit 6d50b752 authored by Filipa Lacerda's avatar Filipa Lacerda

[ci skip] Enable etag polling

parent 7a98970b
......@@ -3,6 +3,7 @@ module NotesActions
extend ActiveSupport::Concern
included do
before_action :set_polling_interval_header, only: [:index]
before_action :authorize_admin_note!, only: [:update, :destroy]
before_action :note_project, only: [:create]
end
......@@ -175,6 +176,12 @@ module NotesActions
)
end
def set_polling_interval_header
return unless noteable.is_a?(Issue)
Gitlab::PollingInterval.set_header(response, interval: 3_000)
end
def noteable
@noteable ||= notes_finder.target
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment