浏览代码

Remove deprecated method

Matt Coles 9 年之前
父节点
当前提交
b4ccf0566c
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      index.js

+ 1 - 1
index.js

@@ -18,7 +18,7 @@ scheduler.register_existing_events();
18 18
 var auth = function (req, res, next) {
19 19
   function unauthorized(res) {
20 20
     res.set('WWW-Authenticate', 'Basic realm=Authorization Required');
21
-    return res.send(401);
21
+    return res.sendStatus(401);
22 22
   };
23 23
 
24 24
   var user = basic_auth(req);