Skip to content

Commit bf9cbde

Browse files
committed
github.event.pull_request.merge_commit_sha may be empty
1 parent 63f6f87 commit bf9cbde

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tool/auto-style.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ class Git
1111

1212
def initialize(oldrev, newrev, branch = nil)
1313
@oldrev = oldrev
14-
@newrev = newrev
14+
@newrev = newrev.empty? ? 'HEAD' : newrev
1515
@branch = branch
1616

1717
# GitHub may not fetch github.event.pull_request.base.sha at checkout

0 commit comments

Comments
 (0)