⚗️ pixiv增加token登录
This commit is contained in:
10
lib/request/httpsProxyAgentMod.js
Normal file
10
lib/request/httpsProxyAgentMod.js
Normal file
@@ -0,0 +1,10 @@
|
||||
import HttpsProxyAgentOrig from 'https-proxy-agent'
|
||||
|
||||
export class HttpsProxyAgent extends HttpsProxyAgentOrig {
|
||||
constructor (opts) {
|
||||
super(opts)
|
||||
this.tlsConnectionOptions = opts.tls
|
||||
const callback = this.callback.bind(this)
|
||||
this.callback = (req, opts) => callback(req, Object.assign(opts, this.tlsConnectionOptions))
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user