App crash with memory leak after hitting "cancel" button in dialog

Hi there,

I’ve been working on an own app that includes the jitsi sdk for video conferencing on Android.
Mainly I changed some theme things and in my Android project I simply open the jitsi activity. So far so good.

When I try to enter a room when I’m not the host, I get the dialog that informs me about that. Still expected behaviour.
Now, hitting cancel brings me back to the device’s home screen. Some seconds later, LeakCanary complains, that the MainActivity is leaking:

HEAP ANALYSIS RESULT
    ====================================
    1 APPLICATION LEAKS
    
    References underlined with "~~~" are likely causes.
    Learn more at https://squ.re/leaks.
    
    72099 bytes retained by leaking objects
    Signature: 6173255683997cea5a863ec78ff85dede6c116
    ┬───
    │ GC Root: Global variable in native code
    │
    ├─ dalvik.system.PathClassLoader instance
    │    Leaking: NO (SoLoader↓ is not leaking and A ClassLoader is never leaking)
    │    ↓ PathClassLoader.runtimeInternalObjects
    ├─ java.lang.Object[] array
    │    Leaking: NO (SoLoader↓ is not leaking)
    │    ↓ Object[].[590]
    ├─ com.facebook.soloader.SoLoader class
    │    Leaking: NO (a class is never leaking)
    │    ↓ static SoLoader.sBackupSoSources
    │                      ~~~~~~~~~~~~~~~~
    ├─ com.facebook.soloader.UnpackingSoSource[] array
    │    Leaking: UNKNOWN
    │    ↓ UnpackingSoSource[].[0]
    │                          ~~~
    ├─ com.facebook.soloader.ApkSoSource instance
    │    Leaking: UNKNOWN
    │    ↓ ApkSoSource.mContext
    │                  ~~~~~~~~
    ╰→ <appname>.MainActivity instance
    ​     Leaking: YES (ObjectWatcher was watching this because de.qwertiko.meet.MainActivity received Activity#onDestroy() callback and Activity#mDestroyed is true)
    ​     key = cae55a22-9a30-4fa8-94c6-b1fbc229ca6d
    ​     watchDurationMillis = 5209
    ​     retainedDurationMillis = 200
    ====================================
    0 LIBRARY LEAKS
    
    A Library Leak is a leak caused by a known bug in 3rd party code that you do not have control over.
    See https://square.github.io/leakcanary/fundamentals-how-leakcanary-works/#4-categorizing-leaks
    ====================================
    METADATA
    
    Please include this in bug reports and Stack Overflow questions.
    
    Build.VERSION.SDK_INT: 29
    Build.MANUFACTURER: OnePlus
    LeakCanary version: 2.3
    App process name: <appname>
    Analysis duration: 8635 ms
    Heap dump file path: /data/user/0/<appname>/files/leakcanary/2020-05-28_23-06-42_002.hprof
    Heap dump timestamp: 1590700014275
    ====================================

The app does not seem to crash (no crash visible in logcat and still running according to AS), but it is a weird behaviour.

When I run the app directly from react-native (“npx react-native run-anroid”), the behaviour of the mentioned button is normal - upon click I return to the app’s welcome page.

My problem is I have no idea where to start the dig…