Skip to content

Commit 4116b88

Browse files
author
Duncan Alexander
authored
changed type detection in get-key (#290)
1 parent 3b214e5 commit 4116b88

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

addon/-private/utils/get-key.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ let _serializeParams = function(params={}, prefix) {
44
.map((key) => {
55
const value = params[key];
66

7-
if (params.constructor === Array) {
7+
if (Array.isArray(params)) {
88
key = `${prefix}[]`;
9-
} else if (params.constructor === Object) {
9+
} else if (params === Object(params)) {
1010
key = (prefix ? `${prefix}[${key}]` : key);
1111
}
1212

0 commit comments

Comments
 (0)