Open MaganAnkur opened 4 years ago
It's because of UNUserNotificationCenter
part in didFinishLaunchingWithOptions
(AppDelegate.m)
@kasterlod okay, makes sense, but can it be put somewhere else so we can call requestPermissions()
at a specific time from the react layer?
How do i lately ask for permission ?
Where can it be put in order to delay the requestPermissions()
It's because of
UNUserNotificationCenter
part indidFinishLaunchingWithOptions
(AppDelegate.m)
For some reason the popup asking permission for the push notifications is showing automatically when the app is opened for the first time even if I am configuring Push Notification later in the app.
Please let me know the way how can I stop auto ask permission on app launch.
Below is my componentDidMount code in entry file:
`componentDidMount() { AppState.addEventListener('change', this.appStateDidChange) Orientation.lockToPortrait() Orientation.addDeviceOrientationListener(this.orientationDidChange) this.unsubscribeAuthStateChangeListener = firebase .auth() .onAuthStateChanged(this.authStateDidChange) this.unsubscribeNetInfoStatListener = NetInfo.addEventListener( this.props.setNetStat )
}`