Skip to content

Commit

Permalink
Call AnnotationRegistry::registerLoader() only if it exists
Browse files Browse the repository at this point in the history
  • Loading branch information
W0rma committed Jan 31, 2023
1 parent 8dbebb1 commit 57be209
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/bootstrap.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,7 @@

$loader->add('Hateoas\Tests', __DIR__);

AnnotationRegistry::registerLoader('class_exists');
// Method has been removed in doctrine/annotations:2
if (method_exists(AnnotationRegistry::class, 'registerLoader')) {
AnnotationRegistry::registerLoader('class_exists');
}

0 comments on commit 57be209

Please sign in to comment.