Skip to content

Commit 6ca46fd

Browse files
committed
Dont pass internals down to childrern
1 parent 5ffb4cd commit 6ca46fd

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/firebaseConnect.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,11 @@ export const createFirebaseConnect = (storeKey = 'store') => (
9292
}
9393

9494
render() {
95-
return <WrappedComponent {...this.props} />
95+
// Prevent internal refs from being passed down to children
96+
let props = { ...this.props }
97+
delete props._firebaseRef
98+
delete props._dispatch
99+
return <WrappedComponent {...props} />
96100
}
97101
}
98102

0 commit comments

Comments
 (0)