Skip to content

Commit 96d6654

Browse files
committed
Merge pull request #4 from finico/feature/clone-null
clone value if it's null
2 parents 982f03c + 84d27a1 commit 96d6654

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function decorator (Component) {
5656
}
5757

5858
function clone (val) {
59-
if (typeof val !== 'object') {
59+
if (val === null || typeof val !== 'object') {
6060
return val
6161
} else if (Array.isArray(val)) {
6262
return val.map(clone)

0 commit comments

Comments
 (0)