@@ -11,7 +11,7 @@ import { BaseSQLiteDatabase, getTableConfig as getSqliteTableConfig, SQLiteTable
1111
1212import type { AbstractGenerator } from './services/GeneratorsWrappers.ts' ;
1313import { generatorsFuncs } from './services/GeneratorsWrappers.ts' ;
14- import seedService from './services/SeedService.ts' ;
14+ import { SeedService } from './services/SeedService.ts' ;
1515import type { DrizzleStudioObjectType , DrizzleStudioRelationType } from './types/drizzleStudio.ts' ;
1616import type { RefinementsType } from './types/seedService.ts' ;
1717import type { Column , Relation , RelationWithReferences , Table } from './types/tables.ts' ;
@@ -251,6 +251,8 @@ export async function seedForDrizzleStudio(
251251 ? schemasRefinements [ schemaName ]
252252 : undefined ;
253253
254+ const seedService = new SeedService ( ) ;
255+
254256 const generatedTablesGenerators = seedService . generatePossibleGenerators (
255257 sqlDialect ,
256258 tables ,
@@ -489,6 +491,8 @@ const seedPostgres = async (
489491 options : { count ?: number ; seed ?: number } = { } ,
490492 refinements ?: RefinementsType ,
491493) => {
494+ const seedService = new SeedService ( ) ;
495+
492496 const { tables, relations, tableRelations } = getPostgresInfo ( schema ) ;
493497 const generatedTablesGenerators = seedService . generatePossibleGenerators (
494498 'postgresql' ,
@@ -740,6 +744,8 @@ const seedMySql = async (
740744) => {
741745 const { tables, relations, tableRelations } = getMySqlInfo ( schema ) ;
742746
747+ const seedService = new SeedService ( ) ;
748+
743749 const generatedTablesGenerators = seedService . generatePossibleGenerators (
744750 'mysql' ,
745751 tables ,
@@ -927,6 +933,8 @@ const seedSqlite = async (
927933) => {
928934 const { tables, relations, tableRelations } = getSqliteInfo ( schema ) ;
929935
936+ const seedService = new SeedService ( ) ;
937+
930938 const generatedTablesGenerators = seedService . generatePossibleGenerators (
931939 'sqlite' ,
932940 tables ,
@@ -1072,3 +1080,4 @@ export { default as cities } from './datasets/cityNames.ts';
10721080export { default as countries } from './datasets/countries.ts' ;
10731081export { default as firstNames } from './datasets/firstNames.ts' ;
10741082export { default as lastNames } from './datasets/lastNames.ts' ;
1083+ export { SeedService } from './services/SeedService.ts' ;
0 commit comments