backgroundMessageHandler function
void
backgroundMessageHandler(
- SmsMessage message
Handles incoming SMS messages while the app is in the background.
Must be a top-level function so the telephony plugin can call it from a
background isolate. Passed to listenIncomingSms by TextMessageProbe.
Implementation
void backgroundMessageHandler(SmsMessage message) async {
_textMessageProbeController.add(Measurement.fromData(TextMessage.fromSmsMessage(message)));
}