 private extension UIView {
 
     func anchorForEdge(edge: EdgeAnchor) -> NSLayoutAnchor {
-        switch edge {
-
-        case EdgeAnchor.leading:
+        if edge == .leading {
             return self.leadingAnchor
-
-        case EdgeAnchor.trailing:
+        } else if edge == .trailing {
             return self.trailingAnchor
-
-        case EdgeAnchor.top:
+        } else if edge == .top {
             return self.topAnchor
-
-        case EdgeAnchor.bottom:
+        } else if edge == .bottom {
             return self.bottomAnchor
-
-        case EdgeAnchor.centerX:
+        } else if edge == .centerX {
             return self.centerXAnchor
-
-        case EdgeAnchor.centerY:
+        } else if edge == .centerY {
             return self.centerYAnchor
-
-        case EdgeAnchor.width:
+        } else if edge == .width {
             return self.widthAnchor
-
-        case EdgeAnchor.height:
+        } else if edge == .height {
             return self.heightAnchor
-
-        default:
+        } else {
             fatalError("There is an unhandled edge case with edges. Get it? Edge case… 😂")
         }
     }


public extension UIView {

    func pinToSuperview(edges: [EdgeAnchor] = EdgeAnchor.allEdges, activate: Bool = true) -> [NSLayoutConstraint] {
        if let superview = self.superview {
            return self.pinToView(superview, edges: edges, activate: activate)
        } else {

        }
    }

    func pinToView(view: UIView, edges: [EdgeAnchor] = EdgeAnchor.allEdges, relation: NSLayoutRelation = .Equal, activate: Bool = true) -> [NSLayoutConstraint] {
        let addConstraint: (edge: EdgeAnchor) -> NSLayoutConstraint? = { edge in
            if edges.contains(edge) {
                let constant: CGFloat
