You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thrownew \LogicException(sprintf('Route to "%s" is missing paths for locale(s) "%s".', $class->name.'::'.$method->name, implode('", "', array_keys($missing))));
169
+
} else {
170
+
foreach ($pathas$locale => $localePath) {
171
+
if (!isset($prefix[$locale])) {
172
+
thrownew \LogicException(sprintf('Route to "%s" with locale "%s" is missing a corresponding prefix in class "%s".', $method->name, $locale, $class->name));
173
+
}
174
+
175
+
$paths[$locale] = $prefix[$locale].$localePath;
176
+
}
177
+
}
178
+
} elseif (\is_array($prefix)) {
179
+
foreach ($prefixas$locale => $localePrefix) {
180
+
$paths[$locale] = $localePrefix.$path;
181
+
}
182
+
} else {
183
+
$paths[] = $prefix.$path;
184
+
}
163
185
164
-
$collection->add($name, $route);
186
+
foreach ($method->getParameters() as$param) {
187
+
if (isset($defaults[$param->name]) || !$param->isDefaultValueAvailable()) {
188
+
continue;
189
+
}
190
+
foreach ($pathsas$locale => $path) {
191
+
if (false !== strpos($path, sprintf('{%s}', $param->name))) {
thrownew \LogicException(sprintf('Collection "%s" is missing prefixes for locale(s) "%s".', $this->name, implode('", "', array_keys($missing))));
72
+
} else {
73
+
foreach ($prefixas$locale => $localePrefix) {
74
+
if (!isset($this->parentPrefixes[$locale])) {
75
+
thrownew \LogicException(sprintf('Collection "%s" with locale "%s" is missing a corresponding prefix in its parent collection.', $this->name, $locale));
thrownew \InvalidArgumentException(sprintf('Route "%s" with locale "%s" is missing a corresponding prefix in its parent collection.', $name, $locale));
0 commit comments