@@ -20,7 +20,6 @@ import {
20
20
UpdateOneOptions
21
21
} from '@ptc-org/nestjs-query-core'
22
22
import { DeleteResult , FindOptionsWhere , Repository } from 'typeorm'
23
- import { DriverUtils } from 'typeorm/driver/DriverUtils'
24
23
import { QueryDeepPartialEntity } from 'typeorm/query-builder/QueryPartialEntity'
25
24
import { UpdateResult } from 'typeorm/query-builder/result/UpdateResult'
26
25
@@ -56,8 +55,6 @@ export class TypeOrmQueryService<Entity>
56
55
57
56
readonly useSoftDelete : boolean
58
57
59
- private readonly isMySQL : boolean
60
-
61
58
constructor (
62
59
readonly repo : Repository < Entity > ,
63
60
opts ?: TypeOrmQueryServiceOpts < Entity >
@@ -66,8 +63,6 @@ export class TypeOrmQueryService<Entity>
66
63
67
64
this . filterQueryBuilder = opts ?. filterQueryBuilder ?? new FilterQueryBuilder < Entity > ( this . repo )
68
65
this . useSoftDelete = opts ?. useSoftDelete ?? false
69
-
70
- this . isMySQL = DriverUtils . isMySQLFamily ( repo . manager . connection . driver )
71
66
}
72
67
73
68
// eslint-disable-next-line @typescript-eslint/naming-convention
@@ -89,9 +84,6 @@ export class TypeOrmQueryService<Entity>
89
84
* @param query - The Query used to filter, page, and sort rows.
90
85
*/
91
86
public async query ( query : Query < Entity > , opts ?: QueryOptions < Entity > ) : Promise < Entity [ ] > {
92
- if ( this . isMySQL && query . paging ?. offset && ! query . paging ?. limit ) {
93
- query = { ...query , paging : { ...query . paging , limit : Number . MAX_SAFE_INTEGER } }
94
- }
95
87
const qb = this . filterQueryBuilder . select ( query )
96
88
97
89
if ( opts ?. withDeleted ) {
0 commit comments