 		disconnectButton.isEnabled = isClient
 		hostingSwitch.isEnabled = !isClient
 	}
+	
+	private func stopListening()
+	{
+		queryManager?.stop()
+		queryManager?.removeListeners()
+	}
 }

		print("STATUS: QR Capture session cancelled")
	}
	
	func rowsUpdated(rows: [Row<BookView>])
	{
		do
		{

		{
			print("ERROR: Failed to read through book data")
		}
	}
	
	func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int
	{
		return books.count
	}
	
	func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell
	{
		let cell = tableView.dequeueReusableCell(withIdentifier: LabelCell.identifier, for: indexPath) as! LabelCell
		
		cell.configure(text: "\(books[indexPath.row].code.uppercased()) - \(books[indexPath.row].identifier)")
		
		return cell
	}
	
	func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath)
	{
		// Moves to the main translation view
		let storyboard = UIStoryboard(name: "MainMenu", bundle: nil)
		guard let controller = storyboard.instantiateInitialViewController() else
		{
			print("ERROR: Failed to instantiate the translation view")
			return
		}
		
		// TODO: Sets the book ready for the translation VC
		present(controller, animated: true, completion: nil)
	}
	
	
