processRetroCompatibility method

  1. @visibleForTesting
Map<String, dynamic> processRetroCompatibility(
  1. Map<String, dynamic> dataMap
)
inherited

Implementation

@visibleForTesting
Map<String, dynamic> processRetroCompatibility(Map<String, dynamic> dataMap) {
  if (dataMap.containsKey('autoCancel')) {
    developer.log(
        'autoCancel is now deprecated. Please use autoDismissible instead.');
    dataMap[NOTIFICATION_AUTO_DISMISSIBLE] =
        AwesomeAssertUtils.extractValue<bool>('autoCancel', dataMap);
  }
  for (MapEntry<String, dynamic> entry in dataMap.entries) {
    if (entry.value == 'AppKilled') {
      developer
          .log('AppKilled is now deprecated. Please use Terminated instead.');
      dataMap[entry.key] = NotificationLifeCycle.Terminated.name;
    }
  }
  return dataMap;
}