0

I'm trying to integrate Google nearby messages Api into my application but I'm getting the error "UIAlertView is deprecated and unavailable for UIScene based applications, please use UIAlertController"

I've gotten it integrated properly but I'm pretty sure the SDK is outdated/depreciated. Any advice on what todo?

I've posted my code to GitHub https://github.com/Rezolution88/GNMessagesTrial/tree/main

import UIKit

class TableViewController: UITableViewController {
    
    let data = Array(repeating: "Item", count: 5)
    let name = "Nick"
    
    let messageManager = GNSMessageManager(apiKey: "AIz739486ygfhjgqKx-Oadx3xkfsdkjfhs8ywbKfmtywTc")

    @IBOutlet var mainTableView: UITableView!
    
    override func viewDidLoad() {
        super.viewDidLoad()

        
        let publication =
            messageManager?.publication(with: GNSMessage(content: name.data(using: .utf8)))
        //print(publication)
        
        print(data)
        
        
        
        mainTableView.dataSource = self
        mainTableView.register(UINib(nibName: "tableCell", bundle: nil), forCellReuseIdentifier: "ReusabelCell")
        self.mainTableView.reloadData()
vadian
  • 253,546
  • 28
  • 306
  • 323
Nick
  • 1
  • 1

0 Answers0