mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-21 02:29:23 +00:00
fix(load) ajax: if data is array - nothing working out
This commit is contained in:
parent
8a2006b8a2
commit
6b11242c53
1 changed files with 2 additions and 1 deletions
|
|
@ -160,6 +160,7 @@ var Util, DOM;
|
|||
var data,
|
||||
p = params, countProgress,
|
||||
isObject = Util.isObject(p.data),
|
||||
isArray = Util.isArray(p.data),
|
||||
type = p.type || p.method || 'GET',
|
||||
xhr = new XMLHttpRequest();
|
||||
|
||||
|
|
@ -168,7 +169,7 @@ var Util, DOM;
|
|||
if (p.responseType)
|
||||
xhr.responseType = p.responseType;
|
||||
|
||||
if (isObject)
|
||||
if (isObject || isArray)
|
||||
data = Util.stringifyJSON(p.data);
|
||||
else
|
||||
data = p.data;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue