(obj)
| 1533 | } |
| 1534 | |
| 1535 | function toKeyValue(obj) { |
| 1536 | var parts = []; |
| 1537 | forEach(obj, function(value, key) { |
| 1538 | if (isArray(value)) { |
| 1539 | forEach(value, function(arrayValue) { |
| 1540 | parts.push(encodeUriQuery(key, true) + |
| 1541 | (arrayValue === true ? '' : '=' + encodeUriQuery(arrayValue, true))); |
| 1542 | }); |
| 1543 | } else { |
| 1544 | parts.push(encodeUriQuery(key, true) + |
| 1545 | (value === true ? '' : '=' + encodeUriQuery(value, true))); |
| 1546 | } |
| 1547 | }); |
| 1548 | return parts.length ? parts.join('&') : ''; |
| 1549 | } |
| 1550 | |
| 1551 | |
| 1552 | /** |
no test coverage detected