UIViewControllerInteractiveTransitioning for dismiss needs explicit setNeedsStatusBarAppearanceUpdate?

I have a UIViewControllerInteractiveTransitioning conforming class that animates the dismissing from the presented view controller (ViewControllerGreen) that prefers its status bar hidden to the presenting view controller (ViewControllerRed) that does not. The presentation is done with a modalPresentationStyle = .custom and modalPresentationCapturesStatusBarAppearance = true.

The presenting view controller has a navigation controller and
showing status bar. I would expect that after dismissing the presented view controller the status bar returns to the state it was in before presenting (i.e. status bar being shown), but this does not happen without an explicit call to setNeedsStatusBarAppearanceUpdate at the right time.

Is there something wrong in my implementation of the InteractiveTransitioningControllerGreenToRed that triggers this?

I created a code sample that should compile and run on Xcode 12.4 targeting Simulator iOS 14.4.

Thanks for any help.
UIViewControllerInteractiveTransitioning for dismiss needs explicit setNeedsStatusBarAppearanceUpdate?
 
 
Q