                 
                 self.presentViewController(shareMenu, animated: true, completion: nil)
             }
-        )
-        
-        var deleteAction = UITableViewRowAction(style: .Default, title: "Delete",
-            handler: { (action: UITableViewRowAction!, indexPath: NSIndexPath!) in
+        
+        
+        var deleteAction = UITableViewRowAction(style: .Default, title: "Delete") {
+            (action: UITableViewRowAction!, indexPath: NSIndexPath!) in
                 self.restaurantNames.removeAtIndex(indexPath.row)
                 self.restaurantIsVisited.removeAtIndex(indexPath.row)
                 tableView.deleteRowsAtIndexPaths([indexPath], withRowAnimation: .Fade)
             }
-        )
         
         return [shareAction, deleteAction]
     }

                    //cell.accessoryType =  self.restaurantIsVisited[indexPath.row] ? .Checkmark : .None
                    cell.restaurantVisited.text = self.restaurantIsVisited[indexPath.row] ? "♥️" : ""
                }
        })
    
        optionMenu.addAction(isVisitedAction)
        presentViewController(optionMenu, animated: true, completion: nil)

    // have to implement delete mechanism also
    
    override func tableView(tableView: UITableView, editActionsForRowAtIndexPath indexPath: NSIndexPath) -> [AnyObject]? {
        var shareAction = UITableViewRowAction(style: .Default, title: "Share") {
            (action: UITableViewRowAction!, indexPath: NSIndexPath!) -> Void in
                let shareMenu = UIAlertController(title: nil, message: "Share using", preferredStyle: .ActionSheet)
                let twitterAction = UIAlertAction(title: "Twitter", style: .Default, handler: nil)
                let facebookAction = UIAlertAction(title: "Facebook", style: .Default, handler: nil)
