Skip to content

Commit

Permalink
Use ::class instead of get_class()
Browse files Browse the repository at this point in the history
  • Loading branch information
BenMorel committed Oct 17, 2023
1 parent c4acefb commit 777c3a2
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
3 changes: 0 additions & 3 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,6 @@
<InvalidReturnType>
<code><![CDATA[ArrayIterator<int, T>]]></code>
</InvalidReturnType>
<MixedArgument>
<code>$geometry</code>
</MixedArgument>
</file>
<file src="src/IO/EWKTParser.php">
<InvalidClassConstantType>
Expand Down
2 changes: 1 addition & 1 deletion src/GeometryCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public function __construct(CoordinateSystem $cs, Geometry ...$geometries)
'%s expects instance of %s, instance of %s given.',
static::class,
$containedGeometryType,
get_class($geometry)
$geometry::class
));
}
}
Expand Down
2 changes: 1 addition & 1 deletion tests/AbstractTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ final protected function expectExceptionIn(Closure $closure, string $exceptionCl
try {
$closure();
} catch (Throwable $exception) {
if (get_class($exception) === $exceptionClass) {
if ($exception::class === $exceptionClass) {
$this->addtoAssertionCount(1);
return;
}
Expand Down

0 comments on commit 777c3a2

Please sign in to comment.