Skip to content

Commit 7864c9a

Browse files
committed
Update PanModalPresentationDelegate.swift
Fix slackhq#208
1 parent b2f5bd7 commit 7864c9a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

PanModal/Delegate/PanModalPresentationDelegate.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ extension PanModalPresentationDelegate: UIViewControllerTransitioningDelegate {
5252
Changes in size class during presentation are handled via the adaptive presentation delegate
5353
*/
5454
public func presentationController(forPresented presented: UIViewController, presenting: UIViewController?, source: UIViewController) -> UIPresentationController? {
55-
let controller = PanModalPresentationController(presentedViewController: presented, presenting: presenting)
55+
let controller = PanModalPresentationController(presentedViewController: presented, presenting: presenting ?? source)
5656
controller.delegate = self
5757
return controller
5858
}

0 commit comments

Comments
 (0)