Skip to content

Commit

Permalink
fix(git): add check empty commit on parse
Browse files Browse the repository at this point in the history
  • Loading branch information
marcocesarato committed Feb 13, 2021
1 parent 81dd44d commit a26d6ae
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Git/Commit.php
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,11 @@ public function getMentions(): array
*/
protected function parse()
{
// Empty
if (empty($this->raw)) {
return;
}

$rows = explode("\n", $this->raw);

$subject = $rows[0];
Expand Down

0 comments on commit a26d6ae

Please sign in to comment.