Remove irrelevant button errors in console
This commit is contained in:
parent
4ce76dbe90
commit
d40420ad2b
@ -6,8 +6,6 @@ import './css/Button.css';
|
|||||||
class Button extends Component {
|
class Button extends Component {
|
||||||
// Multiple onClick functions
|
// Multiple onClick functions
|
||||||
onClick = () => {
|
onClick = () => {
|
||||||
console.log(this.props.onClick);
|
|
||||||
|
|
||||||
if (this.props.onClick !== null
|
if (this.props.onClick !== null
|
||||||
&& this.props.onClick !== undefined) {
|
&& this.props.onClick !== undefined) {
|
||||||
if (Array.isArray(this.props.onClick)) {
|
if (Array.isArray(this.props.onClick)) {
|
||||||
@ -17,8 +15,6 @@ class Button extends Component {
|
|||||||
} else {
|
} else {
|
||||||
console.log("Error when parsing Button onClick functions.");
|
console.log("Error when parsing Button onClick functions.");
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
console.log("Error when parsing Button onClick functions.");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user