@@ -25,7 +25,7 @@ export function isCustomComponentElement(inst, adapter) {
2525function propsOfNode ( node ) {
2626 return entries ( ( node && node . props ) || { } )
2727 . filter ( ( [ , value ] ) => typeof value !== 'undefined' )
28- . reduce ( ( acc , [ key , value ] ) => ( { ... acc , [ key ] : value } ) , { } ) ;
28+ . reduce ( ( acc , [ key , value ] ) => Object . assign ( acc , { [ key ] : value } ) , { } ) ;
2929}
3030
3131export function typeOfNode ( node ) {
@@ -141,7 +141,7 @@ function childrenToArray(children) {
141141 const result = [ ] ;
142142
143143 const push = ( el ) => {
144- if ( el === null || el === false || el === undefined ) return ;
144+ if ( el === null || el === false || typeof el === ' undefined' ) return ;
145145 result . push ( el ) ;
146146 } ;
147147
@@ -161,7 +161,7 @@ export function childrenToSimplifiedArray(nodeChildren) {
161161 const child = childrenArray [ i ] ;
162162 const previousChild = simplifiedArray . pop ( ) ;
163163
164- if ( previousChild === undefined ) {
164+ if ( typeof previousChild === ' undefined' ) {
165165 simplifiedArray . push ( child ) ;
166166 } else if ( isTextualNode ( child ) && isTextualNode ( previousChild ) ) {
167167 simplifiedArray . push ( previousChild + child ) ;
@@ -220,11 +220,11 @@ export function nodeHasProperty(node, propKey, propValue) {
220220 }
221221 const nodePropValue = nodeProps [ propKey ] ;
222222
223- if ( nodePropValue === undefined ) {
223+ if ( typeof nodePropValue === ' undefined' ) {
224224 return false ;
225225 }
226226
227- if ( propValue !== undefined ) {
227+ if ( typeof propValue !== ' undefined' ) {
228228 return is ( nodePropValue , propValue ) ;
229229 }
230230
0 commit comments