Skip to content

Commit fd22f71

Browse files
authored
Merge pull request #489 from yshngg/patch-1
fix(migrations): skip unhandled AI providers during migration execution
2 parents c107078 + 3d42dde commit fd22f71

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

src/migrations/_run.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,19 @@ export const runMigrations = async () => {
3636
const config = getConfig();
3737
if (config.OCO_AI_PROVIDER === OCO_AI_PROVIDER_ENUM.TEST) return;
3838

39+
// skip unhandled providers in migration00
40+
if (
41+
[
42+
OCO_AI_PROVIDER_ENUM.DEEPSEEK,
43+
OCO_AI_PROVIDER_ENUM.GROQ,
44+
OCO_AI_PROVIDER_ENUM.MISTRAL,
45+
OCO_AI_PROVIDER_ENUM.MLX,
46+
OCO_AI_PROVIDER_ENUM.OPENROUTER,
47+
].includes(config.OCO_AI_PROVIDER)
48+
) {
49+
return;
50+
}
51+
3952
const completedMigrations = getCompletedMigrations();
4053

4154
let isMigrated = false;

0 commit comments

Comments
 (0)