diff --git a/Source/SideMenuController.swift b/Source/SideMenuController.swift index a4f1aa9..69fdaae 100644 --- a/Source/SideMenuController.swift +++ b/Source/SideMenuController.swift @@ -89,6 +89,14 @@ public extension SideMenuController { */ public func embed(centerViewController controller: UIViewController, cacheIdentifier: String? = nil) { + guard controller !== centerViewController else { + if sidePanelVisible { + animate(toReveal: false) + } + + return + } + if let id = cacheIdentifier { controllersCache[id] = controller }