We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents ceb10f9 + 785373d commit 28853daCopy full SHA for 28853da
Routing/RestRouteCollection.php
@@ -62,7 +62,10 @@ public function prependRouteControllersWithPrefix($prefix)
62
public function setDefaultFormat($format)
63
{
64
foreach (parent::all() as $route) {
65
- $route->setDefault('_format', $format);
+ // Set default format only if not set already (could be defined in annotation)
66
+ if (!$route->getDefault('_format')) {
67
+ $route->setDefault('_format', $format);
68
+ }
69
}
70
71
0 commit comments