     }
 
     func setTableView(toHideAddItemRow hideAddItemRow: Bool) {
+        guard
+            let searchCancelButton = searchCancelButton,
+            let cancelButtonBlurView = cancelButtonBlurView,
+            let searchCancelButtonWidthConstraint = searchCancelButtonWidthConstraint,
+            let searchCancelButtonLeadingConstraint = searchCancelButtonLeadingConstraint
+        else { return }
+
         DispatchQueue.main.async {
             let constraintAnimations = {
-                self.searchCancelButtonWidthConstraint.constant = hideAddItemRow ? 60 : 0
-                self.searchCancelButtonLeadingConstraint.constant = hideAddItemRow ? 20 : 0
+                searchCancelButtonWidthConstraint.constant = hideAddItemRow ? 60 : 0
+                searchCancelButtonLeadingConstraint.constant = hideAddItemRow ? 20 : 0
                 self.view.layoutIfNeeded()
             }
 
             let alphaAnimations = {
-                self.searchCancelButton.alpha = hideAddItemRow ? 1 : 0
-                self.cancelButtonBlurView.alpha = hideAddItemRow ? 1 : 0
+                searchCancelButton.alpha = hideAddItemRow ? 1 : 0
+                cancelButtonBlurView.alpha = hideAddItemRow ? 1 : 0
             }
 
             if hideAddItemRow {

public class CrudSearchContainer: UIView {}

public protocol CrudViewControllerSearchDelegate {
    func crudViewController(crudViewController: CrudViewController, predicateForSearchString string: String) -> NSPredicate
}


private extension CrudViewController {

    func setLookAndFeel() {
        if searchDelegate.crudViewControllerShouldEnableSearch(crudViewController: self), let searchField = searchField, let searchContainer = searchContainer, let searchCancelButton = searchCancelButton {
            let fieldBlurView = UIVisualEffectView(effect: UIBlurEffect(style: UIBlurEffectStyle.dark))
            cancelButtonBlurView = UIVisualEffectView(effect: UIBlurEffect(style: UIBlurEffectStyle.dark))
            guard let cancelButtonBlurView = cancelButtonBlurView else { return }
            cancelButtonBlurView.alpha = 0
            let blurs: [UIView] = [ fieldBlurView, cancelButtonBlurView ]
            blurs.forEach {
                self.view.insertSubview($0, belowSubview: searchContainer)
            }
            fieldBlurView.edgeAnchors == searchField.edgeAnchors
            cancelButtonBlurView.edgeAnchors == searchCancelButton.edgeAnchors

            let searchViews: [UIView] = [ searchField, searchCancelButton ]
            searchViews.forEach { $0.layer.borderWidth = 2 * UIScreen.main.hairlineWidth }

            (blurs + searchViews).forEach {
                $0.clipsToBounds = true
                $0.layer.cornerRadius = 10
            }

            searchField.layer.borderColor = searchField.tintColor.cgColor
            searchCancelButton.layer.borderColor = searchCancelButton.tintColor.cgColor

            searchCancelButton.setTitleColor(searchCancelButton.tintColor, for: .normal)
        }
    }

    func resetSearch() {
