Use early retutn node pattern
This commit is contained in:
parent
d5c552a03a
commit
a585ba5480
@ -92,12 +92,12 @@ AnalysesController.prototype.catalog = function (req, res, next) {
|
|||||||
err.http_status = 401;
|
err.http_status = 401;
|
||||||
}
|
}
|
||||||
|
|
||||||
next(err);
|
return next(err);
|
||||||
} else {
|
}
|
||||||
|
|
||||||
res.body = { catalog: catalogWithTables };
|
res.body = { catalog: catalogWithTables };
|
||||||
next();
|
next();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user