class HackerOne::Client::Activities::Activity
Attributes
activity[R]
Public Class Methods
new(activity)
click to toggle source
# File lib/hackerone/client/activity.rb, line 10 def initialize(activity) @activity = OpenStruct.new activity end
Public Instance Methods
attachments()
click to toggle source
# File lib/hackerone/client/activity.rb, line 18 def attachments @attachments ||= activity.relationships.fetch(:attachments, {}) .fetch(:data, []) .map { |attachment| HackerOne::Client::Attachment.new(attachment) } end
internal?()
click to toggle source
# File lib/hackerone/client/activity.rb, line 14 def internal? attributes.internal end
Private Instance Methods
attributes()
click to toggle source
# File lib/hackerone/client/activity.rb, line 30 def attributes OpenStruct.new(activity.attributes) end
relationships()
click to toggle source
# File lib/hackerone/client/activity.rb, line 26 def relationships OpenStruct.new(activity.relationships) end