Add missing reject statements

feature/threejs-update
Robin Hawkes 2016-09-05 16:35:54 +01:00
rodzic 89ea1ee87d
commit 5be99841ff
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 1EC4C2D6765FA8CF
3 zmienionych plików z 9 dodań i 9 usunięć

Wyświetl plik

@ -63,7 +63,7 @@ class GeoJSONWorkerLayer extends Layer {
transferrables.push(geojson.buffer);
this._execWorker(geojson, this._options.topojson, this._world._originPoint, style, this._options.interactive, transferrables).then(() => {
resolve();
});
}).catch(reject);
} else if (typeof this._options.onEachFeature === 'function') {
GeoJSONWorkerLayer.RequestGeoJSON(geojson).then((res) => {
var fc = GeoJSON.collectFeatures(res, this._options.topojson);
@ -80,12 +80,12 @@ class GeoJSONWorkerLayer extends Layer {
this._execWorker(geojson, false, this._options.headers, this._world._originPoint, style, this._options.interactive, transferrables).then(() => {
resolve();
});
}).catch(reject);
});
} else {
this._execWorker(geojson, this._options.topojson, this._options.headers, this._world._originPoint, style, this._options.interactive, transferrables).then(() => {
resolve();
});
}).catch(reject);
}
});
}
@ -291,9 +291,9 @@ class GeoJSONWorkerLayer extends Layer {
});
var point;
var projected = converted.map(_coordinates => {
return _coordinates.map(ring => {
return ring.map(latlon => {
var projected = converted.map((_coordinates) => {
return _coordinates.map((ring) => {
return ring.map((latlon) => {
point = Geo.latLonToPoint(latlon)._subtract(originPoint);
if (!pointScale) {

Wyświetl plik

@ -234,7 +234,7 @@ class PolygonLayer extends Layer {
// TODO: Ensure that this has feature parity with the non-static method
static SetBufferAttributes(coordinates, options) {
return new Promise((resolve, reject) => {
return new Promise((resolve) => {
var height = 0;
// Convert height into world units

Wyświetl plik

@ -22,7 +22,7 @@ class WorkerPool {
Promise.all(workerPromises).then(() => {
if (DEBUG) { console.log('All workers ready', performance.now()); }
resolve();
});
}).catch(reject);
});
}
@ -41,7 +41,7 @@ class WorkerPool {
this.workers.push(worker);
resolve();
});
}).catch(reject);
});
}