Post

Replies

Boosts

Views

Activity

Reply to What is the payload for Location push extension?
class LocationHelper{     var locationManager:CLLocationManager          init(){         locationManager = CLLocationManager()                           locationManager.startMonitoringLocationPushes(completion: onMonitorUpdated)     }     func request(){         let status = locationManager.authorizationStatus         print(status == .authorizedAlways)         locationManager.requestAlwaysAuthorization()              }          func onMonitorUpdated(data:Data?, error:Error?){         print(" error:\(error?.localizedDescription)")         guard let data = data else {             return         }         let token = data.reduce("", {$0 + String(format: "%02X", $1)})                  print("token is:\(token)")     }      }
Oct ’21