diff --git a/lib/cijoe/server.rb b/lib/cijoe/server.rb index 01ebafe..684f54b 100644 --- a/lib/cijoe/server.rb +++ b/lib/cijoe/server.rb @@ -39,7 +39,10 @@ def self.start(host, port, project_path) end post '/' do - joe.build if params[:payload].to_s.include? joe.git_branch + payload = params[:payload].to_s + if payload.empty? || payload.include?(joe.git_branch) + joe.build + end redirect '/' end