                 }
         }
     }
+
+    func disableDoNotDisturb(#failed: () -> Void) {
+
+        let realm = Realm()
+
+        if let
+            myUserID = YepUserDefaults.userID.value,
+            me = userWithUserID(myUserID, inRealm: realm) {
+
+                if let userDoNotDisturb = me.doNotDisturb {
+
+                    let info: JSONDictionary = [
+                        "mute_started_at_string": "",
+                        "mute_ended_at_string": "",
+                    ]
+
+                    updateMyselfWithInfo(info, failureHandler: { [weak self] (reason, errorMessage) in
+                        defaultFailureHandler(reason, errorMessage)
+
+                        dispatch_async(dispatch_get_main_queue()) {
+                            YepAlert.alertSorry(message: errorMessage ?? NSLocalizedString("Disable Do Not Disturb failed!", comment: ""), inViewController: self)
+                        }
+
+                        failed()
+
+                    }, completion: { success in
+
+                        dispatch_async(dispatch_get_main_queue()) {
+
+                            let realm = Realm()
+
+                            if let
+                                myUserID = YepUserDefaults.userID.value,
+                                me = userWithUserID(myUserID, inRealm: realm) {
+
+                                    if let userDoNotDisturb = me.doNotDisturb {
+                                        realm.write {
+                                            realm.delete(userDoNotDisturb)
+                                        }
+                                    }
+                            }
+                        }
+                    })
+                }
+        }
+    }
 }
 
 // MARK: - UITableViewDataSource, UITableViewDelegate


                if isOn {
                    self?.tableView.insertRowsAtIndexPaths([indexPath], withRowAnimation: .Automatic)
                } else {
                    self?.tableView.deleteRowsAtIndexPaths([indexPath], withRowAnimation: .Automatic)
                }

                if isOn {
                    self?.enableDoNotDisturb(failed: {
                        dispatch_async(dispatch_get_main_queue()) {
                            self?.doNotDisturbPeriod.isOn = false
                            self?.tableView.deleteRowsAtIndexPaths([indexPath], withRowAnimation: .Automatic)
                        }
                    })
                }

                        defaultFailureHandler(reason, errorMessage)

                        dispatch_async(dispatch_get_main_queue()) {
                            YepAlert.alertSorry(message: errorMessage ?? NSLocalizedString("Enable Do Not Disturb failed!", comment: ""), inViewController: self)
                        }

                        failed()
