Jay
cbda78552b
Revert "Bug/allow header to contain http verb keys #1252 ( #1258 )" ( #2977 )
...
This reverts commit 920510b3a6 .
2020-05-22 21:44:26 +02:00
David Ko
920510b3a6
Bug/allow header to contain http verb keys #1252 ( #1258 )
...
* Failing test for #1252
* Only delete header keys that match an HTTP verb if the value is a non-string
Co-authored-by: David Ko <david.ko@pvtmethod.com >
Co-authored-by: Jay <jasonsaayman@gmail.com >
2020-05-22 21:26:10 +02:00
Alan Wang
885ada6d9b
Fixing getting local files (file://) failed ( #2470 )
...
* fix issue #2416 , #2396
* fix Eslint warn
* Modify judgment conditions
* add unit test
* update unit test
* update unit test
2020-03-23 21:49:38 +08:00
Gustavo López
6642ca9aa1
Add independent maxBodyLength option ( #2781 )
...
* Add independent option to set the maximum size of the request body
* Remove maxBodyLength check
* Update README
* Assert for error code and message
2020-03-06 21:55:19 +08:00
Thibault Ehrhart
17a967123c
Adding responseEncoding to mergeConfig ( #1745 )
...
Co-authored-by: Xianming Zhong <chinesedfan@qq.com >
2020-02-15 21:49:26 +08:00
Jonathan Sharpe
77f0ae4f61
Fix merging of params ( #2656 )
...
* Name function to avoid ESLint func-names warning
* Switch params config to merge list and update tests
* Restore testing of both false and null
* Restore test cases for keys without defaults
* Include test for non-object values that aren't false-y.
2020-02-15 13:36:52 +08:00
不才
ee47120a09
If this place is false, it will report an error, so you should delete the useless code. ( #2458 )
2019-12-25 13:00:15 -08:00
Felipe Martins
097948698a
Revert "Update Webpack + deps, remove now unnecessary polyfills" ( #2479 )
...
* Revert "Update Webpack + deps, remove now unnecessary polyfills (#2410 )"
This reverts commit 189b34c45a .
* Fix build (#2496 )
* Change syntax to see if build passes
* Test commit
* Test with node 10
* Test adding all browsers in travis
* remove other browsers when running on travis
2019-10-25 11:34:47 -03:00
Avindra Goolcharan
189b34c45a
Update Webpack + deps, remove now unnecessary polyfills ( #2410 )
...
* Update deps
* handles webpack 1 -> 4 migration
* remove promise helpers from dev files
assume `Promise` is available, or polyfilled by
the consumer
* Remove isArray util. `isArray` has good coverage, even
in IE9. So lets remove the custom polyfill.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray
also resolves a few lint issues
* Remove trim util
String.protoype.trim has good coverage (including IE9)
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/Trim
Also, the http adapter already uses the native method.
2019-10-21 15:56:29 -03:00
Rafael Renan Pacheco
a11cdf4683
Fixing custom config options ( #2207 )
...
- fixes #2203
2019-09-06 21:40:04 -03:00
bushuai
e50a08b2c3
Fixing set config.method after mergeConfig for Axios.prototype.request ( #2383 )
...
Inside Axios.prototype.request function, It's forced to set
method to 'get' after `mergeConfig` if config.method exists, which makes the defaults.method not effective.
2019-09-06 14:23:55 -03:00
DIO
89bd3abe9a
Axios create url bug ( #2290 )
...
* Fix #2234
* added spacing --eslint
* added test cases
* removed unexpected cases after updating the code
2019-09-06 12:45:18 -03:00
multicolaure
6fe506fda2
Do not modify config.url when using a relative baseURL ( resolves #1628 ) ( #2391 )
...
* Adding tests to show config.url mutation
Because config.url is modified while processing the request
when the baseURL is set,
it is impossible to perform a retry with the provided config object.
Ref #1628
* Fixing url combining without modifying config.url
As config.url is not modified anymore during the request processing.
The request can safely be retried after it failed with the provided
config.
resolves #1628
2019-09-05 12:43:55 -03:00
Ayush Gupta
b681e919c4
Adding isAxiosError flag to errors thrown by axios ( #1419 )
2018-08-20 11:02:23 +02:00
Anthony Gauthier
4f98acc578
Add getUri method ( #1712 )
...
* Added getUri method
* Removed usage of "url"
* added method to README
2018-08-07 11:52:30 -06:00
Tim Johns
6b44e80ade
Added toJSON to decorated Axios errors to faciliate serialization ( #1625 )
2018-08-06 23:33:55 -06:00
Rikki Gibson
503418718f
Remove XDomainRequest special status handling
2018-08-06 09:56:51 +02:00
Martti Laine
4e8039ef65
Remember socketPath in mergeConfig
2018-04-10 22:29:02 +02:00
Martti Laine
143bbbe1b9
Spec for mergeConfig, finalize logic
2018-04-07 15:54:56 +02:00
Martti Laine
ff61caacb7
Slight refactor/namings/comment on mergeConfig
2018-04-07 13:40:21 +02:00
Martti Laine
b1c378606f
Prevent undefined values in mergeConfig
2018-04-03 22:29:15 +02:00
Martti Laine
6083d639c5
Rename mergeConfig arguments
2018-04-03 22:19:19 +02:00
Martti Laine
72c66dfdec
Refactor and introduce deepMerge
2018-03-23 20:21:02 +01:00
Martti Laine
d78204712a
Clean up PR
2018-03-09 13:58:08 +02:00
Martti Laine
5bfd2ea9f6
Fixing #385 - Keep defaults local to instance
2018-03-02 12:31:15 +02:00
Haven
2b8562694e
Fixing baseURL not working in interceptors ( #950 )
...
* Fixing baseURL not working in interceptors
* add test for modify base URL in request interceptor
2017-08-12 14:15:27 +02:00
杨春旭
e4e32120ce
Convert the method parameter to lowercase
2017-05-31 22:53:11 +08:00
Martin Joiner
1beb245f3a
Fixing typo in comment blocks of createError() and enhanceError() functions ( #857 )
2017-05-28 22:03:40 +02:00
Rubén Norte
22ce6db383
Adding request to error objects when it is available
2017-04-08 21:44:15 +02:00
Nick Uraltsev
2fe95621b0
Merge pull request #461 from theikkila/master
...
Add OPTIONS-method as a shortcut
2017-03-26 21:06:24 -07:00
Nick Uraltsev
6d0e19343a
Fixing bug with custom intances and global defaults
2016-11-26 18:17:21 -08:00
Teemu Heikkilä
2e0adc1cae
Add OPTIONS-method as a shortcut
2016-09-29 18:54:17 +03:00
Nick Uraltsev
e9fbe959d2
Updating dispatchRequest to use isCancel instead of instanceof
2016-09-23 15:58:25 -07:00
Nick Uraltsev
032916e116
Merging master
2016-09-23 15:54:47 -07:00
Nick Uraltsev
72dd897bb5
Adding cancellation support
2016-09-17 11:52:56 -07:00
Rubén Norte
b2745873a1
Moving default adapter to global defaults
2016-09-05 21:30:29 +02:00
Matt Zabriskie
98d489558e
Transform response data on error
...
closes #378
2016-07-16 11:10:58 -06:00
Rubén Norte
157efd5615
Changing adapter signature to receive config and return promises
2016-07-09 21:30:16 +02:00
Rubén Norte
235c19c876
Implementing adapter error enhacement
2016-07-07 16:05:04 +02:00
Matt Zabriskie
46eee269da
Fixing custom instance defaults
...
closes #341
2016-06-23 15:19:10 -06:00
Matt Zabriskie
10eb238651
Move transform response logic from adapters to dispatcher
2016-06-23 15:11:35 -06:00
Matt Zabriskie
e833a2f7e4
Invoke request transformers after request interceptors
...
closes #352
2016-06-23 14:55:22 -06:00
Matt Zabriskie
f21784ccb8
Removing restriction on withCredentials being overridden
...
closes #343
2016-06-23 14:04:27 -06:00
Nick Uraltsev
6f2186d863
Modify createError and enhanceError functions to accept response as parameter
2016-06-13 18:58:55 -07:00
Nick Uraltsev
91dae3c4ad
Improve error handling
2016-06-13 13:56:08 -07:00
Matt Zabriskie
0e2f4f1417
Moving Axios class into core/
2016-06-01 14:42:14 -06:00
Matt Zabriskie
203cbc2da0
Moving settle & transformData from helpers/ -> core/
2016-06-01 13:54:38 -06:00
Matt Zabriskie
eea790b8de
Adding README to modules
2016-06-01 13:16:16 -06:00
Matt Zabriskie
7cf19f64c4
Reverting #234
2016-04-20 22:28:01 -06:00
samueleaton
ddc965831c
switches check order of xhr/http for electron
2016-02-15 22:38:56 -07:00