Skip to content

Commit

Permalink
~ Explain things and fix code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
tylernathanreed committed Jul 25, 2021
1 parent 028f6d0 commit 7068f80
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/Mixins/JoinsRelationships.php
Original file line number Diff line number Diff line change
Expand Up @@ -251,9 +251,21 @@ protected function getJoinType()
return null;
}

// There's a weird quirk in PHP where if a dynamic property was added
// to a class, and the class has the magic "__get" method defined,
// accessing the property yields a value, but also throws too.

try {
$type = $this->type;
} finally {
}

// There's a bug with code coverage that for whatever reason does not
// consider the "finally" line to be covered, but its contents are.
// While it looks weird, we are going to ignore coverage there.

// @codeCoverageIgnoreStart
finally {
// @codeCoverageIgnoreEnd
return $type;
}
};
Expand Down

0 comments on commit 7068f80

Please sign in to comment.