mirror of
https://github.com/fosrl/pangolin.git
synced 2026-08-08 21:48:02 +02:00
support changing capabilities on provider integrations
This commit is contained in:
@@ -124,6 +124,15 @@ export async function createAiProvider(
|
||||
capabilities
|
||||
});
|
||||
|
||||
if (resolvedCapabilities.length === 0) {
|
||||
return next(
|
||||
createHttpError(
|
||||
HttpCode.BAD_REQUEST,
|
||||
"At least one capability is required"
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
const [provider] = await db
|
||||
.insert(aiProviders)
|
||||
.values({
|
||||
|
||||
Reference in New Issue
Block a user