fetchPreferredNotificationLanguage method Null safety
Gets the push translation language set by the user.
Return has set language code.
Throws A description of the exception. See {@link ChatError}.
Implementation
Future<String?> fetchPreferredNotificationLanguage() async {
Map result = await _channel.invokeMethod(
ChatMethodKeys.fetchPreferredNotificationLanguage,
);
try {
ChatError.hasErrorFromResult(result);
String? ret = result[ChatMethodKeys.fetchPreferredNotificationLanguage];
return ret;
} on ChatError catch (e) {
throw e;
}
}