File tree 2 files changed +5
-4
lines changed
2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ class OgcConnection extends Connection {
44
44
}
45
45
return Boolean ( spec && spec . ogcapi ) ;
46
46
} ) ;
47
- let requestBody = Migrate . executeSync ( openEO ) ;
47
+ let requestBody = Migrate . executeSync ( this . connection , openEO ) ;
48
48
let headers = { } ;
49
49
if ( mode === 'async' ) {
50
50
headers . Prefer = 'respond-async' ;
Original file line number Diff line number Diff line change @@ -161,20 +161,21 @@ class OgcMigrate {
161
161
* Executes an OGC API process synchronously.
162
162
*
163
163
* @todo Check whether implementation still works
164
+ * @param {Connection } connection
164
165
* @param {object } requestBody
165
166
* @returns {object }
166
167
*/
167
- static executeSync ( requestBody ) {
168
+ static executeSync ( connection , requestBody ) {
168
169
const graph = Object . values ( requestBody . process . process_graph ) ;
169
170
const valid = graph . every ( node => {
170
- let spec = OgcMigrate . connection . processes . get ( node . process_id ) ;
171
+ let spec = connection . processes . get ( node . process_id ) ;
171
172
return Boolean ( spec && ( spec . ogcapi || spec . id === 'load_collection' ) ) ;
172
173
} ) ;
173
174
if ( ! valid ) {
174
175
throw new Error ( 'Process must consist only of OGC Processes and Collections' ) ;
175
176
}
176
177
177
- const parser = new PgParser ( requestBody . process , OgcMigrate . connection . getBaseUrl ( ) ) ;
178
+ const parser = new PgParser ( requestBody . process , connection . getBaseUrl ( ) ) ;
178
179
return parser . parse ( ) ;
179
180
}
180
181
You can’t perform that action at this time.
0 commit comments