Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 5ff4d10

Browse files
committed
feat($httpParamSerializerJQLike): honor object.toJSON function if present.
1 parent 9ea52d8 commit 5ff4d10

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ng/http.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ function $HttpParamSerializerJQLikeProvider() {
111111
forEach(toSerialize, function(value) {
112112
serialize(value, prefix + '[]');
113113
});
114-
} else if (isObject(toSerialize) && !isDate(toSerialize)) {
114+
} else if (isObject(toSerialize) && !isFunction(toSerialize.toJSON)) {
115115
forEachSorted(toSerialize, function(value, key) {
116116
serialize(value, prefix +
117117
(topLevel ? '' : '[') +

0 commit comments

Comments
 (0)