Skip to content

Commit 58a7302

Browse files
committed
Fix types
1 parent 30daa13 commit 58a7302

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

types/index.d.ts

+24
Original file line numberDiff line numberDiff line change
@@ -1030,6 +1030,25 @@ declare global {
10301030
}
10311031
const User: UserConstructor;
10321032

1033+
type LogLevels = 'error' | 'warn' | 'info' | 'debug' | 'verbose' |'silly';
1034+
interface LoggerInterface {
1035+
1036+
log(level : LogLevels, args : any) : void
1037+
1038+
info(args : any): LoggerInterface
1039+
1040+
error(args : any): LoggerInterface
1041+
1042+
warn(args : any): LoggerInterface
1043+
1044+
verbose(args : any): LoggerInterface
1045+
1046+
debug(args : any): LoggerInterface
1047+
1048+
silly(args : any): LoggerInterface
1049+
}
1050+
1051+
10331052
/**
10341053
* A Parse.Schema object is for handling schema data from Parse.
10351054
* All the schemas methods require MasterKey.
@@ -1292,6 +1311,10 @@ declare global {
12921311
interface JobRequest<T extends Params = Params> {
12931312
params: T;
12941313
message: (response: any) => void;
1314+
log: LoggerInterface,
1315+
headers?: any;
1316+
ip: string;
1317+
jobName : string,
12951318
}
12961319

12971320
interface Params {
@@ -1307,6 +1330,7 @@ declare global {
13071330

13081331
interface ValidatorField {
13091332
type?: any;
1333+
required?: boolean;
13101334
constant?: boolean;
13111335
default?: any;
13121336
options?: any[]|Function;

0 commit comments

Comments
 (0)