Skip to content

Commit

Permalink
fixup! TF-2533 part 3 replace beforeunload with pagehide
Browse files Browse the repository at this point in the history
  • Loading branch information
tddang-linagora committed Apr 17, 2024
1 parent 2bd52e2 commit 3d6abda
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ class _HtmlContentViewerOnWebState extends State<HtmlContentViewerOnWeb> {
window.parent.addEventListener('message', handleMessage, false);
window.addEventListener('click', handleOnClickLink, true);
window.addEventListener('load', handleOnLoad);
window.addEventListener('beforeunload', (event) => {
window.addEventListener('pagehide', (event) => {
window.parent.removeEventListener('message', handleMessage, false);
});
Expand Down

0 comments on commit 3d6abda

Please sign in to comment.