setPushTemplate method

Future<void> setPushTemplate(
  1. String pushTemplateName
)

Sets the template for offline push notifications.

Param pushTemplateName The push template name.

Throws A description of the exception. See ChatError.

Implementation

Future<void> setPushTemplate(String pushTemplateName) async {
  Map result =
      await PushChannel.invokeMethod(ChatMethodKeys.setPushTemplate, {
    "pushTemplateName": pushTemplateName,
  });
  try {
    ChatError.hasErrorFromResult(result);
  } on ChatError catch (e) {
    throw e;
  }
}