@ai-sdk/openai 2.0.94 → 2.0.95
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +13 -0
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/dist/internal/index.js +1 -1
- package/dist/internal/index.js.map +1 -1
- package/dist/internal/index.mjs +1 -1
- package/dist/internal/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/internal/index.js
CHANGED
|
@@ -993,7 +993,7 @@ var OpenAIChatLanguageModel = class {
|
|
|
993
993
|
for (const toolCallDelta of delta.tool_calls) {
|
|
994
994
|
const index = toolCallDelta.index;
|
|
995
995
|
if (toolCalls[index] == null) {
|
|
996
|
-
if (toolCallDelta.type !== "function") {
|
|
996
|
+
if (toolCallDelta.type != null && toolCallDelta.type !== "function") {
|
|
997
997
|
throw new import_provider3.InvalidResponseDataError({
|
|
998
998
|
data: toolCallDelta,
|
|
999
999
|
message: `Expected 'function' type.`
|