Skip to content
This repository has been archived by the owner on Dec 24, 2023. It is now read-only.

Commit

Permalink
fix: this fixes issue 30
Browse files Browse the repository at this point in the history
  • Loading branch information
wswebcreation committed Aug 20, 2019
1 parent f96ebc7 commit 918859b
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions lib/clientSideScripts/hideScrollbars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,13 @@
* Hide the scrollbars
*/
export default function hideScrollBars(hide: boolean): void {
if (hide) {
document.body.style.overflow = 'hidden';
} else {
document.body.style.overflow = '';
try {
if (hide) {
document.body.style.overflow = 'hidden';
} else {
document.body.style.overflow = '';
}
} catch (e) {
// Do nothing
}
}

0 comments on commit 918859b

Please sign in to comment.