1
0
mirror of https://github.com/sasjs/server.git synced 2026-01-09 23:40:06 +00:00

chore: modify the implementation files and executor api

This commit is contained in:
2021-10-18 19:50:30 +00:00
parent 91e2e2bc4a
commit a42a1693c2
3 changed files with 25 additions and 7 deletions

View File

@@ -6,5 +6,12 @@ export interface ExecutionQuery {
_debug?: boolean
}
export const isRequestQuery = (arg: any): arg is ExecutionQuery =>
export interface FileQuery {
filePath: string
}
export const isExecutionQuery = (arg: any): arg is ExecutionQuery =>
arg && !Array.isArray(arg) && typeof arg._program === 'string'
export const isFileQuery = (arg: any): arg is FileQuery =>
arg && !Array.isArray(arg) && typeof arg.filePath === 'string'