CartoDB-SQL-API/lib/batch/models/query/query-factory.js
Daniel García Aubert 5a96dbb59c Run eslint --fix
2019-12-23 18:19:08 +01:00

17 lines
352 B
JavaScript

'use strict';
var QueryFallback = require('./query-fallback');
function QueryFactory () {
}
module.exports = QueryFactory;
QueryFactory.create = function (job, index) {
if (QueryFallback.is(job.query.query[index])) {
return new QueryFallback(job, index);
}
throw new Error('there is no query class for the provided query');
};