Closed NaturelLee closed 7 years ago
!!Object.keys(obj).length
这个改动有问题,当对象为空的时候isEmptyObject函数返回true,表明这是个空对象。
isEmptyObject
true
!Object.keys( { } ).length === true
!!Object.keys(obj).length