Skip to content

Commit 75c8f6c

Browse files
committed
retain weird bool support for this value
1 parent d66c81e commit 75c8f6c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/Github/Api/PullRequest.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,10 @@ public function merged($username, $repository, $id)
154154

155155
public function merge($username, $repository, $id, $message, $sha, $mergeMethod = 'merge', $title = null)
156156
{
157+
if (is_bool($mergeMethod)) {
158+
$mergeMethod = $mergeMethod ? 'squash' : 'merge';
159+
}
160+
157161
if (!in_array($mergeMethod, array('squash', 'rebase'))) {
158162
$mergeMethod = 'merge';
159163
}

0 commit comments

Comments
 (0)