diff --git a/src/oauthproxy.js b/src/oauthproxy.js index d398f0352..64d549e25 100644 --- a/src/oauthproxy.js +++ b/src/oauthproxy.js @@ -121,7 +121,7 @@ function authenticate(req, res, next) { return res.send(500, 'Unknown app.'); } - clientdb.getByAppId(result.id, clientdb.TYPE_PROXY, function (error, result) { + clientdb.getByAppIdAndType(result.id, clientdb.TYPE_PROXY, function (error, result) { if (error) { console.error('Unkonwn OAuth client.', error); return res.send(500, 'Unknown OAuth client.');