Class: Request::Payload::Github
- Inherits:
-
Github::ServiceHook::Payload
- Object
- OpenStruct
- Github::ServiceHook::Payload
- Request::Payload::Github
- Defined in:
- lib/travis/model/request/payload/github.rb
Instance Attribute Summary
Attributes inherited from Github::ServiceHook::Payload
Instance Method Summary collapse
- #attributes ⇒ Object
-
#initialize(data, token) ⇒ Github
constructor
A new instance of Github.
- #reject? ⇒ Boolean
Methods inherited from Github::ServiceHook::Payload
#commits, #compare_url, #last_commit, #repository
Methods inherited from OpenStruct
Constructor Details
#initialize(data, token) ⇒ Github
Returns a new instance of Github.
6 7 8 9 |
# File 'lib/travis/model/request/payload/github.rb', line 6 def initialize(data, token) super(data) self.token = token end |
Instance Method Details
#attributes ⇒ Object
11 12 13 |
# File 'lib/travis/model/request/payload/github.rb', line 11 def attributes { :source => source, :payload => payload, :commit => last_commit.to_hash, :token => token } end |
#reject? ⇒ Boolean
15 16 17 |
# File 'lib/travis/model/request/payload/github.rb', line 15 def reject? no_commit? || repository.private? || skipped? || github_pages? end |