/
githubmirror
/
strapi
Обзор
Документация
Войти
/
githubmirror
/
strapi
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
develop
packages/core/database/src/repairs/index.ts
13 строк
595 B
markkaylor
fix: database is corrupt with orphaned relations (#24316)
23 сен 2025, 11:11
Не верифицирован
23 сен 2025, 11:11
536eed0
Код
Авторство
О чём код?
import type { Database } from '..'; import { removeOrphanMorphType as removeOrphanMorphTypeFunc } from './operations/remove-orphan-morph-types'; import { processUnidirectionalJoinTables } from './operations/process-unidirectional-join-tables'; import { asyncCurry } from '../utils/async-curry'; export const createRepairManager = (db: Database) => { return { removeOrphanMorphType: asyncCurry(removeOrphanMorphTypeFunc)(db), processUnidirectionalJoinTables: asyncCurry(processUnidirectionalJoinTables)(db), }; }; export type RepairManager = ReturnType<typeof createRepairManager>;