capacitor-community / privacy-screen

⚡️ Capacitor plugin that protects your app from displaying a screenshot in Recents screen/App Switcher.
MIT License
87 stars 23 forks source link

bug: app crashes on iOS when changing screen orientation #65

Closed aljadan closed 1 year ago

aljadan commented 1 year ago

Plugin version: 4.1.1

Platform(s): iOS

Current behavior: When I enable the plugin on an iOS device and subsequently change the screen orientation, the app crashes. However, if I enable the plugin more than once, it functions correctly without any crash.

Expected behavior: The app should not crash after enabling the plugin

Steps to reproduce: Scenario 1: App Crash

Enable the plugin on an iOS device. Change the screen orientation. Observe that the app crashes.

Scenario 2: No Crash

Enable the plugin on an iOS device. Disable the plugin. Re-enable the plugin. Change the screen orientation. Notice that the app works fine without any crash.

https://github.com/capacitor-community/privacy-screen/assets/111672775/40f168a4-fd06-450b-85b8-060f903e229a

robingenz commented 1 year ago

Thank you for your request. Please provide a Minimal, Reproducible Example using this template in a public GitHub repository so I can debug the issue.

aljadan commented 1 year ago

Thank you for your request. Please provide a Minimal, Reproducible Example using this template in a public GitHub repository so I can debug the issue.

Example

robingenz commented 1 year ago

Thank you, I will test this next week and get back to you.

robingenz commented 1 year ago

Okay, i just tested it and close this issue as a duplicate of #64.