Skip to content

Commit b69dd55

Browse files
committed
Use non-deprecated method
1 parent 29b9d36 commit b69dd55

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

src/Routing/Loader/AttributeLoader.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,11 @@ public function __construct(?string $env = null)
1717
{
1818
parent::__construct($env);
1919

20-
$this->setRouteAnnotationClass(AsMessageHandler::class);
20+
if (method_exists($this, 'setRouteAttributeClass')) {
21+
$this->setRouteAttributeClass(AsMessageHandler::class);
22+
} else {
23+
$this->setRouteAnnotationClass(AsMessageHandler::class);
24+
}
2125
}
2226

2327
/**

0 commit comments

Comments
 (0)