From adb415f72c3cbb2564c5f27a3fee8bfdad7c972e Mon Sep 17 00:00:00 2001 From: "Subramaniam, Ramya" Date: Fri, 21 Jun 2024 12:17:48 +0530 Subject: [PATCH] Making the view nil to prevent dangling contrainst --- MVMCoreUI/Atomic/Organisms/Carousel/Carousel.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/MVMCoreUI/Atomic/Organisms/Carousel/Carousel.swift b/MVMCoreUI/Atomic/Organisms/Carousel/Carousel.swift index 585944bf..3ef117da 100644 --- a/MVMCoreUI/Atomic/Organisms/Carousel/Carousel.swift +++ b/MVMCoreUI/Atomic/Organisms/Carousel/Carousel.swift @@ -307,6 +307,7 @@ open class Carousel: View { pagingView?.removeFromSuperview() bottomPin?.isActive = false + pagingView = nil guard var pagingView = view else { bottomPin = bottomAnchor.constraint(equalTo: collectionView.bottomAnchor)