setPersonProperties method

  1. @override
Future<void> setPersonProperties({
  1. Map<String, Object>? userPropertiesToSet,
  2. Map<String, Object>? userPropertiesToSetOnce,
})

Implementation

@override
Future<void> setPersonProperties({
  Map<String, Object>? userPropertiesToSet,
  Map<String, Object>? userPropertiesToSetOnce,
}) async {
  if ((userPropertiesToSet?.isEmpty ?? true) &&
      (userPropertiesToSetOnce?.isEmpty ?? true)) {
    return;
  }

  return handleWebMethodCall(MethodCall('setPersonProperties', {
    if (userPropertiesToSet != null)
      'userPropertiesToSet': userPropertiesToSet,
    if (userPropertiesToSetOnce != null)
      'userPropertiesToSetOnce': userPropertiesToSetOnce,
  }));
}