Skip to content

Commit ff34467

Browse files
Update sql.md
1 parent 4d4dd6b commit ff34467

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

content/techniques/sql.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -616,11 +616,11 @@ TypeOrmModule.forRootAsync({
616616
imports: [ConfigModule],
617617
useFactory: (configService: ConfigService) => ({
618618
type: 'mysql',
619-
host: configService.get<string>('HOST'),
620-
port: configService.get<number>('PORT'),
621-
username: configService.get<string>('USERNAME'),
622-
password: configService.get<string>('PASSWORD'),
623-
database: configService.get<string>('DATABASE'),
619+
host: configService.get('HOST'),
620+
port: +configService.get<number>('PORT'),
621+
username: configService.get('USERNAME'),
622+
password: configService.get('PASSWORD'),
623+
database: configService.get('DATABASE'),
624624
entities: [__dirname + '/**/*.entity{.ts,.js}'],
625625
synchronize: true,
626626
}),
@@ -1151,11 +1151,11 @@ SequelizeModule.forRootAsync({
11511151
imports: [ConfigModule],
11521152
useFactory: (configService: ConfigService) => ({
11531153
dialect: 'mysql',
1154-
host: configService.get<string>('HOST'),
1155-
port: configService.get<string>('PORT'),
1156-
username: configService.get<string>('USERNAME'),
1157-
password: configService.get<string>('PASSWORD'),
1158-
database: configService.get<string>('DATABASE'),
1154+
host: configService.get('HOST'),
1155+
port: +configService.get('PORT'),
1156+
username: configService.get('USERNAME'),
1157+
password: configService.get('PASSWORD'),
1158+
database: configService.get('DATABASE'),
11591159
models: [],
11601160
}),
11611161
inject: [ConfigService],

0 commit comments

Comments
 (0)