AccountLink.fromJson constructor

AccountLink.fromJson(
  1. Object? json
)

Implementation

factory AccountLink.fromJson(Object? json) {
  final map = (json as Map).cast<String, Object?>();
  return AccountLink(
    created:
        DateTime.fromMillisecondsSinceEpoch((map['created'] as int).toInt()),
    expiresAt: DateTime.fromMillisecondsSinceEpoch(
        (map['expires_at'] as int).toInt()),
    url: (map['url'] as String),
  );
}