Skip to content

Commit 357f69c

Browse files
authored
Merge pull request #822 from yunwuxin/master
Update Trees.php
2 parents af78874 + 1b66f2c commit 357f69c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/Github/Api/GitData/Trees.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public function create($username, $repository, array $params)
5454
}
5555

5656
// If `sha` is not set, `content` is required
57-
if (!isset($tree['sha']) && !isset($tree['content'])) {
57+
if (!array_key_exists('sha', $tree) && !isset($tree['content'])) {
5858
throw new MissingArgumentException("tree.$key.content");
5959
}
6060
}

0 commit comments

Comments
 (0)