toJson method

  1. @override
Map<String, Object?> toJson()

Converts this object into json representation.

Implementation

@override
Map<String, Object?> toJson() {
  return <String, Object?>{
    InsanichessUserJsonKey.id: id,
    InsanichessUserJsonKey.email: email,
    if (password != null) InsanichessUserJsonKey.password: password,
    if (jwtToken != null) InsanichessUserJsonKey.jwtToken: jwtToken,
  };
}