File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -38,9 +38,11 @@ export default class JobsResource {
3838 }
3939
4040 async wait ( id : string ) : Promise < Job > {
41- const response = await this . cloudConvert . axios . get (
42- 'jobs/' + id + '/wait'
43- ) ;
41+ const response = await this . cloudConvert . axios . get ( 'jobs/' + id , {
42+ baseURL : this . cloudConvert . useSandbox
43+ ? 'https://sync.api.sandbox.cloudconvert.com/v2/'
44+ : 'https://sync.api.cloudconvert.com/v2/'
45+ } ) ;
4446 return response . data . data ;
4547 }
4648
Original file line number Diff line number Diff line change @@ -430,9 +430,11 @@ export default class TasksResource {
430430 }
431431
432432 async wait ( id : string ) : Promise < Task > {
433- const response = await this . cloudConvert . axios . get (
434- 'tasks/' + id + '/wait'
435- ) ;
433+ const response = await this . cloudConvert . axios . get ( 'tasks/' + id , {
434+ baseURL : this . cloudConvert . useSandbox
435+ ? 'https://sync.api.sandbox.cloudconvert.com/v2/'
436+ : 'https://sync.api.cloudconvert.com/v2/'
437+ } ) ;
436438 return response . data . data ;
437439 }
438440
You can’t perform that action at this time.
0 commit comments