Skip to content

Commit c44a30a

Browse files
authored
fix: catch undefined StatusBarManager (#1189)
1 parent f5bbad7 commit c44a30a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/helpers/Constants.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ isTablet = Platform.isPad || (getAspectRatio() < 1.6 && Math.max(screenWidth, sc
2020

2121
function setStatusBarHeight() {
2222
const {StatusBarManager} = NativeModules;
23-
statusBarHeight = StatusBarManager.HEIGHT || 0; // So there will be a value for any case
23+
statusBarHeight = StatusBarManager?.HEIGHT || 0; // So there will be a value for any case
2424
// statusBarHeight = isIOS ? 20 : StatusBarManager.HEIGHT;
2525
// if (isIOS) {
2626
// // override guesstimate height with the actual height from StatusBarManager

0 commit comments

Comments
 (0)