updateMyInfo method Null safety

Future<void> updateMyInfo(
  1. {int? birthday,
  2. String? nickname,
  3. String? signature,
  4. String? region,
  5. String? address,
  6. JMGender? gender,
  7. Map? extras}
)

Implementation

Future<void> updateMyInfo(
    {int? birthday,
    String? nickname,
    String? signature,
    String? region,
    String? address,
    JMGender? gender,
    Map<dynamic, dynamic>? extras}) async {
  await _channel.invokeMethod(
      'updateMyInfo',
      {
        'birthday': birthday,
        'nickname': nickname,
        'signature': signature,
        'region': region,
        'address': address,
        'gender': getStringFromEnum(gender),
        'extras': extras,
      }..removeWhere((key, value) => value == null));
  return;
}