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
if (null !== $catalog && isset($catalog->getModels()[$modelId])) {
112
+
if (isset($this->registry->getCatalog($providerId)?->getModels()[$modelId])) {
118
113
return$providerId;
119
114
}
120
115
}
@@ -125,21 +120,11 @@ private function findProviderForModel(string $modelId): string
125
120
continue; // already checked
126
121
}
127
122
128
-
$catalog = $this->getCatalog($providerId);
129
-
if (null !== $catalog && isset($catalog->getModels()[$modelId])) {
123
+
if (isset($this->registry->getCatalog($providerId)?->getModels()[$modelId])) {
130
124
return$providerId;
131
125
}
132
126
}
133
127
134
-
thrownewInvalidArgumentException(\sprintf('Cannot determine provider for model "%s"; Use "provider:model" format to specify it explicitly.', $modelId));
thrownewInvalidArgumentException(\sprintf('Cannot determine provider for model "%s"; Use "provider::model" format to specify it explicitly.', $modelId));
0 commit comments