title: Disable to swipe cell in tableView if condition is false in swift?
body: <pre><code>override func tableView(tableView: UITableView, editActionsForRowAtIndexPath indexPath: NSIndexPath) -&gt; [UITableViewRowAction]? {
  
      if condition == true {
      let pause = UITableViewRowAction(style: .Destructive, title: "pause") { action, index in
              print("pause button tapped")
              return [pause]
          }
      } else {
  
          return .None
      }
  }
  </code></pre>
  
  <blockquote>
    <p>This code didn't disable to swipe in cell. But when swipe the cell delete option appear. Please anyone can help to slove this problem.</p>
  </blockquote>