mirror of
https://github.com/tenrok/axios.git
synced 2026-06-20 20:00:40 +03:00
fix(AxiosHeaders): fix AxiosHeaders conversion to an object during config merging (#6243)
Co-authored-by: Dmitriy Mozgovoy <robotshara@gmail.com>
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
import utils from '../utils.js';
|
import utils from '../utils.js';
|
||||||
import AxiosHeaders from "./AxiosHeaders.js";
|
import AxiosHeaders from "./AxiosHeaders.js";
|
||||||
|
|
||||||
const headersToObject = (thing) => thing instanceof AxiosHeaders ? thing.toJSON() : thing;
|
const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing } : thing;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Config-specific merge-function which creates a new config-object
|
* Config-specific merge-function which creates a new config-object
|
||||||
|
|||||||
Reference in New Issue
Block a user