viewWillTransition(to size called with no size changes

App has a UI stack witch doesn't support orientation changes via:

override var supportedInterfaceOrientations: UIInterfaceOrientationMask {
    return .portrait
}

And it's presenting modally a full-screen ViewController which supports any orientation.

Then if change device orientation while presenting VC, RootViewController of UI below it (the one presenting) gets viewWillTransition notification with size of rotated UI applicable for presented VC (for landscape width = device screen height / height = device screen width):

override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) {
    super.viewWillTransition(to: size, with: coordinator)
    print("Size: \(size)")
  }

...
> Size: (667.0, 375.0)

But afterwards the actual size of the RootViewController's view doesn't changed:

> Size: (375.0, 667.0)

And RootViewController's doesn't receive another viewWillTransition-callback dismissing presented VC with the original size to restore layout.

What am I doing wrong?

Is there a way not to receive viewWillTransition-to-size-callback in case size actually changed or receive it dismissing presented VC with current orientation size?

viewWillTransition(to size called with no size changes
 
 
Q