Skip to content

Commit

Permalink
fix double action call on buttons
Browse files Browse the repository at this point in the history
  • Loading branch information
AlaricBaraou committed Jun 16, 2021
1 parent 57dc6c8 commit 9fdd3de
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/A11y.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -425,8 +425,9 @@ export const A11y: React.FC<Props> = ({
handleBtnClick();
} else if (role === 'togglebutton') {
handleToggleBtnClick();
} else {
if (typeof actionCall === 'function') actionCall();
}
if (typeof actionCall === 'function') actionCall();
}}
onPointerOver={handleOnPointerOver}
onPointerOut={handleOnPointerOut}
Expand Down

0 comments on commit 9fdd3de

Please sign in to comment.