Permalink
Browse files

Recreate pull request if issue labeled with 'pass' or state == 'closed'

  • Loading branch information...
1 parent b84e8a0 commit 0a263b61d6fd34a29577cf613b0bdd2f89555c35 @winton committed Oct 17, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 lib/gitcycle.rb
View
@@ -448,8 +448,11 @@ def ready(*issues)
branch = pull
if branch && !branch['collab']
- force = branch['labels'] && branch['labels'].include?('Pass')
- branch = create_pull_request(branch, force)
+ # Recreate pull request if force == true
+ force = branch['labels'] && branch['labels'].include?('Pass')
+ force ||= branch['state'] && branch['state'] == 'closed'
+
+ branch = create_pull_request(branch, force)
end
if branch == false

0 comments on commit 0a263b6

Please sign in to comment.