empty function fix

This commit is contained in:
FlorianZahn
2021-10-04 21:04:02 +02:00
parent e5fe99c89b
commit 1ad60720df

View File

@@ -27,7 +27,6 @@ export class RectangleTooltip {
props.maxHeight ??= "100px"; props.maxHeight ??= "100px";
props.maxWidth ??= "300px"; props.maxWidth ??= "300px";
this.text = props.text; this.text = props.text;
props.buttonFunction ??= function () {};
this.container = document.createElement('div'); this.container = document.createElement('div');
props.htmlId ??= props.text; props.htmlId ??= props.text;
@@ -70,7 +69,7 @@ export class RectangleTooltip {
<button className="sponsorSkipObject sponsorSkipNoticeButton" <button className="sponsorSkipObject sponsorSkipNoticeButton"
style ={{float: "right" }} style ={{float: "right" }}
onClick={() => { onClick={() => {
props.buttonFunction(); if (props.buttonFunction) props.buttonFunction();
this.close(); this.close();
}}> }}>