@@ -37,8 +37,8 @@ import {
3737 DriverCapabilities
3838} from './driver.interface' ;
3939
40- const sortByKeys = ( unordered ) => {
41- const ordered = { } ;
40+ const sortByKeys = ( unordered : any ) => {
41+ const ordered : any = { } ;
4242
4343 Object . keys ( unordered ) . sort ( ) . forEach ( ( key ) => {
4444 ordered [ key ] = unordered [ key ] ;
@@ -47,7 +47,7 @@ const sortByKeys = (unordered) => {
4747 return ordered ;
4848} ;
4949
50- const DbTypeToGenericType = {
50+ const DbTypeToGenericType : Record < string , string > = {
5151 'timestamp without time zone' : 'timestamp' ,
5252 'character varying' : 'text' ,
5353 varchar : 'text' ,
@@ -78,7 +78,7 @@ const DB_INT_MAX = 2147483647;
7878const DB_INT_MIN = - 2147483648 ;
7979
8080// Order of keys is important here: from more specific to less specific
81- const DbTypeValueMatcher = {
81+ const DbTypeValueMatcher : Record < string , ( ( v : any ) => boolean ) > = {
8282 timestamp : ( v ) => v instanceof Date || v . toString ( ) . match ( / ^ \d \d \d \d - \d \d - \d \d T \d \d : \d \d : \d \d / ) ,
8383 date : ( v ) => v instanceof Date || v . toString ( ) . match ( / ^ \d \d \d \d - \d \d - \d \d $ / ) ,
8484 int : ( v ) => {
@@ -268,7 +268,7 @@ export abstract class BaseDriver implements DriverInterface {
268268 return false ;
269269 }
270270
271- protected informationColumnsSchemaReducer ( result , i ) {
271+ protected informationColumnsSchemaReducer ( result : any , i : any ) {
272272 let schema = ( result [ i . table_schema ] || { } ) ;
273273 const tables = ( schema [ i . table_name ] || [ ] ) ;
274274
@@ -306,7 +306,7 @@ export abstract class BaseDriver implements DriverInterface {
306306 ) ;
307307 }
308308
309- public loadPreAggregationIntoTable ( _preAggregationTableName : string , loadSql : string , params , options ) {
309+ public loadPreAggregationIntoTable ( _preAggregationTableName : string , loadSql : string , params : any , options : any ) {
310310 return this . query ( loadSql , params , options ) ;
311311 }
312312
@@ -407,15 +407,15 @@ export abstract class BaseDriver implements DriverInterface {
407407 return `"${ identifier } "` ;
408408 }
409409
410- protected cancelCombinator ( fn ) {
410+ protected cancelCombinator ( fn : any ) {
411411 return cancelCombinator ( fn ) ;
412412 }
413413
414- public setLogger ( logger ) {
414+ public setLogger ( logger : any ) {
415415 this . logger = logger ;
416416 }
417417
418- protected reportQueryUsage ( usage , queryOptions ) {
418+ protected reportQueryUsage ( usage : any , queryOptions : any ) {
419419 if ( this . logger ) {
420420 this . logger ( 'SQL Query Usage' , {
421421 ...usage ,
@@ -424,7 +424,7 @@ export abstract class BaseDriver implements DriverInterface {
424424 }
425425 }
426426
427- protected databasePoolError ( error ) {
427+ protected databasePoolError ( error : any ) {
428428 if ( this . logger ) {
429429 this . logger ( 'Database Pool Error' , {
430430 error : ( error . stack || error ) . toString ( )
0 commit comments