Class: GithubContributions::Events::IssueCommentEvent

Inherits:
GithubContributions::Event show all
Defined in:
lib/github_contributions/events/issue_comment_event.rb

Instance Attribute Summary

Attributes inherited from GithubContributions::Event

#data

Instance Method Summary collapse

Methods inherited from GithubContributions::Event

#action, #actor, #created_at, #initialize, #name, #org

Constructor Details

This class inherits a constructor from GithubContributions::Event

Instance Method Details

#commentObject



8
9
10
# File 'lib/github_contributions/events/issue_comment_event.rb', line 8

def comment
  @comment ||= GithubObjects::Comment.new(data.payload.comment)
end

#issueObject

Note a pull request comment is classifed as an ‘issue’ although there is a ‘pull_request` attribute in the payload that could be used to id one



14
15
16
# File 'lib/github_contributions/events/issue_comment_event.rb', line 14

def issue
  @issue ||= GithubObjects::Issue.new(data.payload.issue)
end

#payloadObject



4
5
6
# File 'lib/github_contributions/events/issue_comment_event.rb', line 4

def payload
  comment
end