App feedback causes orientation lock to stop working

Hello,

We're using the solution described here to lock the orientation in our app. That works fine most of the time, but it stops working if the App Feedback feature is used (long press with 2 fingers). As soon as the App Feedback UI is closed, the orientation lock no longer works.

Does anyone know how to solve this?