We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8399a2a commit dc617daCopy full SHA for dc617da
src/Model.js
@@ -1,5 +1,6 @@
1
import getProp from 'dotprop'
2
import setProp from 'dset'
3
+import merge from 'merge'
4
import { serialize } from 'object-to-formdata'
5
6
import Builder from './Builder'
@@ -305,7 +306,8 @@ export default class Model extends StaticModel {
305
306
}
307
308
_reqConfig(config, options = { forceMethod: false }) {
- const _config = { ...config, ...this._config }
309
+ // Merge cloned config to prevent changing the original config objects
310
+ const _config = merge.recursive({ ...config }, { ...this._config })
311
312
// Prevent default request method from being overridden
313
if (options.forceMethod) {
0 commit comments