debian-mirror-gitlab/app/graphql/subscriptions/notes/created.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

21 lines
417 B
Ruby
Raw Normal View History

2023-04-23 21:23:45 +05:30
# frozen_string_literal: true
module Subscriptions
module Notes
class Created < Base
payload_type ::Types::Notes::NoteType
def update(*args)
case object
when ResourceEvent
object.work_item_synthetic_system_note
when Array
object.first.work_item_synthetic_system_note(events: object)
else
object
end
end
end
end
end