🐛 bug fix
This commit is contained in:
+1
-1
@@ -3,7 +3,7 @@
|
|||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "node ./bin/www"
|
"start": "node ./app.js"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"cookie-parser": "~1.4.4",
|
"cookie-parser": "~1.4.4",
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ router.get("/", (req, res, next) => {
|
|||||||
|
|
||||||
router.get("/verify", (req, res, next) => {
|
router.get("/verify", (req, res, next) => {
|
||||||
// 验证消息来自微信服务器:https://developers.weixin.qq.com/doc/offiaccount/Basic_Information/Access_Overview.html
|
// 验证消息来自微信服务器:https://developers.weixin.qq.com/doc/offiaccount/Basic_Information/Access_Overview.html
|
||||||
const { signature, timestamp, nonce, echostr } = req.body;
|
const { signature, timestamp, nonce, echostr } = req.query;
|
||||||
const token = process.env.TOKEN;
|
const token = process.env.TOKEN;
|
||||||
let tmp_array = [token, timestamp, nonce].sort();
|
let tmp_array = [token, timestamp, nonce].sort();
|
||||||
let tmp_string = tmp_array.join("");
|
let tmp_string = tmp_array.join("");
|
||||||
|
|||||||
Reference in New Issue
Block a user