diff --git a/lib/stations.js b/lib/stations.js index 4403bef..2b885f9 100644 --- a/lib/stations.js +++ b/lib/stations.js @@ -41,8 +41,9 @@ const filter = (req, res, next) => { const selector = Object.create(null) for (let prop in req.query) { const val = parse(req.query[prop]) - if (prop.slice(0, 12) === 'coordinates.') { // derhuerst/db-rest#2 - prop = 'location.' + prop.slice(12) + // todo: derhuerst/db-rest#2 + if (prop.slice(0, 12) === 'coordinates.') { + prop = prop.slice(12) } selector[prop] = val }