mirror of
https://github.com/DIYgod/RSSHub.git
synced 2025-12-04 02:58:08 +08:00
fix: host in headers after redirecting request (#4717)
This commit is contained in:
@@ -105,11 +105,6 @@ const requestWrapper = (url, options) => {
|
||||
const urlHandler = new URL(url);
|
||||
options.headers.referer = urlHandler.origin;
|
||||
}
|
||||
// host
|
||||
if (!options.headers.host && !options.headers.Host) {
|
||||
const urlHandler = new URL(url);
|
||||
options.headers.host = urlHandler.host;
|
||||
}
|
||||
} catch (e) {
|
||||
// do nothing
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user