mirror of
https://gitlab.com/Binaryify/neteasecloudmusicapi.git
synced 2025-05-23 22:37:41 +08:00
feat: 缓存策略添加hostname #1722
This commit is contained in:
parent
7eca25d390
commit
9d63df78c5
@ -668,8 +668,7 @@ function ApiCache() {
|
||||
req.apicacheTimer = new Date()
|
||||
|
||||
// In Express 4.x the url is ambigious based on where a router is mounted. originalUrl will give the full Url
|
||||
var key = req.originalUrl || req.url
|
||||
|
||||
var key = req.hostname + (req.originalUrl || req.url)
|
||||
// Remove querystring from key if jsonp option is enabled
|
||||
if (opt.jsonp) {
|
||||
key = url.parse(key).pathname
|
||||
|
Loading…
x
Reference in New Issue
Block a user