Liu Song’s Projects


~/Projects/163-music-proxy

git clone https://code.lsong.org/163-music-proxy

Commit

Commit
53ba3e175f19c0de4126b5df16c15773408f267e
Author
binaryify <[email protected]>
Date
2021-09-04 15:03:30 +0800 +0800
Diffstat
 package.json | 2 +-
 util/request.js | 2 ++

修复代理设置问题 #1343


diff --git a/package.json b/package.json
index 27279e197da1566a70ddf792728a7816778b1f0d..e990eaf63e3afb62f91aaeed79fa612b867421f0 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "NeteaseCloudMusicApi",
-  "version": "4.0.20",
+  "version": "4.0.21",
   "description": "网易云音乐 NodeJS 版 API",
   "scripts": {
     "start": "node app.js",




diff --git a/util/request.js b/util/request.js
index 9211aff83f6e2043c9d107c87f93980948fcddfa..bcb245a58a7cc4a4848388c935fc5bc6a6acaab8 100644
--- a/util/request.js
+++ b/util/request.js
@@ -142,6 +142,8 @@         } else {
           console.error('代理配置无效,不使用代理')
         }
       }
+    } else {
+      settings.proxy = false
     }
     if (options.crypto === 'eapi') {
       settings = {