Class: Shipit::GithubHook

Inherits:
Record
  • Object
show all
Defined in:
app/models/shipit/github_hook.rb

Defined Under Namespace

Classes: Organization, Repo

Instance Method Summary collapse

Methods inherited from Record

serializer_class

Instance Method Details

#already_setup?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'app/models/shipit/github_hook.rb', line 21

def already_setup?
  github_id?
end

#apiObject



25
26
27
# File 'app/models/shipit/github_hook.rb', line 25

def api
  Shipit.legacy_github_api
end

#event=(event) ⇒ Object



17
18
19
# File 'app/models/shipit/github_hook.rb', line 17

def event=(event)
  super(event.to_s)
end

#teardown!Object



12
13
14
15
# File 'app/models/shipit/github_hook.rb', line 12

def teardown!
  destroy_hook! if already_setup?
  true
end