XapptorUser.from_snapshot constructor

XapptorUser.from_snapshot(
  1. String id,
  2. String email,
  3. Map<String, dynamic> snapshot
)

Implementation

XapptorUser.from_snapshot(
  String id,
  String email,
  Map<String, dynamic> snapshot,
)   : id = id,
      firstname = snapshot['firstname'],
      lastname = snapshot['lastname'],
      email = email,
      birthday = timestamp_to_date(snapshot['birthday']),
      gender = snapshot['gender'],
      country = snapshot['country'],
      admin = snapshot['admin'] ?? false,
      owner = snapshot['owner'] ?? false;