From a634c61942e9a46569220aef965af489d3b5a5ca Mon Sep 17 00:00:00 2001 From: "Noon, Christian" Date: Tue, 30 Dec 2014 15:08:10 -0800 Subject: [PATCH] Now removing constraints from the view along with uninstalling them. --- Snappy/View+Snappy.swift | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Snappy/View+Snappy.swift b/Snappy/View+Snappy.swift index 8bfc067..8fe2cbe 100644 --- a/Snappy/View+Snappy.swift +++ b/Snappy/View+Snappy.swift @@ -54,9 +54,11 @@ public extension View { ConstraintMaker.remakeConstraints(self, block: block) } - public func snp_uninstallConstraints() { + public func snp_removeConstraints() { for existingLayoutConstraint in LayoutConstraint.layoutConstraintsInstalledOnView(self) { existingLayoutConstraint.constraint?.uninstall() } + + LayoutConstraint.setLayoutConstraints([], installedOnView: self) } } \ No newline at end of file