     }
 
     @IBAction func saveButtonTapped(_ sender: AnyObject) {
+        self.dismissKeyboard()
+        
         self.baby?.givenName = self.givenNameTextField.text
         self.baby?.familyName = self.familyNameTextField.text
         self.baby?.sex = self.sexSegmentedControl.selectedSegmentIndex as NSNumber?

    }

    @IBAction func cancelButtonTapped(_ sender: AnyObject) {
        self.delegate?.editBabyViewController(self, didFinishWithBaby: nil)
        
        // Delete temp image if any

        
        return true
    }
    
    func dismissKeyboard() {
        // Dismiss the keyboard if in note cell
        if let noteCell = tableView.cellForRow(at: IndexPath(row: 0, section: Section.notes.rawValue)) as? NoteCell {
            noteCell.textView.resignFirstResponder()
        }
    }


    // MARK: - Actions
