Use callback to return the error

This commit is contained in:
Daniel García Aubert
2018-07-30 15:57:47 +02:00
parent 94b7353fbf
commit 6be1a77a29
+1 -1
View File
@@ -30,7 +30,7 @@ DataviewBackend.prototype.getDataview = function (mapConfigProvider, user, param
var dataviewDefinition = getDataviewDefinition(mapConfig.obj(), dataviewName);
if (!dataviewDefinition) {
throw new Error("Dataview '" + dataviewName + "' does not exists");
return callback(new Error("Dataview '" + dataviewName + "' does not exists"));
}
var ownFilter = +params.own_filter;