app/controllers/overlay/github_controller.rb in overlay-0.0.5 vs app/controllers/overlay/github_controller.rb in overlay-0.0.6
- old
+ new
@@ -4,11 +4,11 @@
class GithubController < ApplicationController
def update
Overlay.configuration.repositories.each do |repo_config|
next unless repo_config.class == GithubRepo
branch = repo_config[:branch] || 'master'
- if (params[:repository] && params[:webhook])
- if (params[:repository][:name] == repo_config[:repo]) && (params[:webhook][:ref] == "refs/heads/#{branch}")
+ if (params[:repository] && params[:ref])
+ if (params[:repository][:name] == repo_config[:repo]) && (params[:ref] == "refs/heads/#{branch}")
Overlay::Github.process_overlays
end
end
end
render :inline => github_update_url