fixed rest-api issue with token not being checked correctly

This commit is contained in:
Kasper Rynning-Tønnesen
2018-03-04 13:22:59 +01:00
parent 2192b340c9
commit 946bbb1c65

View File

@@ -760,7 +760,7 @@ router.route('/api/conf/:channel_name').post(function(req, res) {
});
function checkOveruseApiToken(authorized, token_docs, res, callback) {
if(authorized || (authorized && token_docs[0].limit == 0)) {
if(!authorized || (authorized && token_docs[0].limit == 0)) {
callback();
return;
}