Skip to content
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.

Commit

Permalink
Fix auth middleware bug
Browse files Browse the repository at this point in the history
  • Loading branch information
alsotang committed Dec 20, 2013
1 parent 460e7f4 commit ee69ff9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion middleware/auth.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ module.exports = function (options) {
}

req.session.name = row.name;
if (config.admins[req.session.name]) {
if (config.admins.hasOwnProperty(req.session.name)) {
req.session.isAdmin = true;
}
debug('auth pass user: %j, onlySync: %s, isAdmin: %s, headers: %j',
Expand Down

0 comments on commit ee69ff9

Please sign in to comment.