                     self?.connectedPeers.remove(at: i)
                     self?.tableView.deleteRows(at: [indexPath], with: .fade)
                 }
+            case .error(.pairingOpperationFailed):
+                self?.dismiss(animated: false, completion: nil)
+                
+                let alert = UIAlertController(
+                    title: "Pairing Failed",
+                    message: "Make sure devices are with in range",
+                    preferredStyle: .alert)
+                
+                alert.addAction(UIAlertAction(title: "OK", style: .cancel, handler: { _ in
+                    self?.dismiss(animated: true, completion: nil)
+                }))
+                
+                self?.present(alert, animated: true, completion: nil)
             case .error(let err):
                 print(err)
             }

            case .initial(let peers):
                self?.connectedPeers = peers
                self?.tableView.reloadData()
            case .connected(let peer):
                if let i = self?.connectedPeers.count {
                    let indexPath = IndexPath(row: i, section: 0)

        }))
        
        self.present(alert, animated: true) { _ in
            Clink.shared.startPairing()
        }
    }
    
