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.
1 parent b34ea46 commit 4b8a3fcCopy full SHA for 4b8a3fc
src/Tree.php
@@ -41,6 +41,10 @@ public function modelForContext(string $context)
41
return $this->models[Str::studly($context)];
42
}
43
44
+ if (isset($this->models[Str::studly(Str::plural($context))])) {
45
+ return $this->models[Str::studly(Str::plural($context))];
46
+ }
47
+
48
$matches = array_filter(array_keys($this->models), function ($key) use ($context) {
49
return Str::endsWith($key, '/' . Str::studly($context));
50
});
0 commit comments