react-reveal icon indicating copy to clipboard operation
react-reveal copied to clipboard

Check children is not null

Open kengreeff opened this issue 6 years ago • 1 comments

Javascript believes that null is an object. If children is null, the evaluation of typeof this.props.children === 'object' returns true`.

When evaluating the next line, typeof child.type === 'string' the script crashes because it can't check type of null.

kengreeff avatar Feb 21 '19 23:02 kengreeff

@noelzubin is there anything holding that PR back? Because the current master breaks things

InsOpDe avatar Mar 26 '21 12:03 InsOpDe