Skip to content

Crash on StandbyFragment when getView is null

Taslim Oseni requested to merge fix-standby-lifecycleowner-crash into develop

Sometimes, the "taking too long" error dialog on StandbyFragment shows up after the connection has already been established. When it happens, it looks like what's on the screenshot below.

Screenshot_20240324_174836

This is a link to the Sentry event.

To fix this, I rewrote the logic such that a nullable version of the error dialog gets dismissed when the connection is successfully established.

As a fail-safe, I also added a null-check to getView at the point where the dialog is interacted with. This way, unavailable views can't be referenced and a crash is unlikely to happen.

Merge request reports