Authenticate reviews with Telegram init data
All checks were successful
Build and deploy Flutter Web / build (push) Successful in 3m1s
All checks were successful
Build and deploy Flutter Web / build (push) Successful in 3m1s
This commit is contained in:
@@ -1,6 +1,38 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:latlong2/latlong.dart';
|
||||
|
||||
class AppUser {
|
||||
const AppUser({
|
||||
required this.id,
|
||||
required this.telegramId,
|
||||
required this.username,
|
||||
required this.firstName,
|
||||
required this.lastName,
|
||||
required this.photoUrl,
|
||||
required this.languageCode,
|
||||
});
|
||||
|
||||
factory AppUser.fromJson(Map<String, dynamic> json) {
|
||||
return AppUser(
|
||||
id: json['id'] as String,
|
||||
telegramId: json['telegramId'] as String,
|
||||
username: json['username'] as String?,
|
||||
firstName: json['firstName'] as String?,
|
||||
lastName: json['lastName'] as String?,
|
||||
photoUrl: json['photoUrl'] as String?,
|
||||
languageCode: json['languageCode'] as String?,
|
||||
);
|
||||
}
|
||||
|
||||
final String id;
|
||||
final String telegramId;
|
||||
final String? username;
|
||||
final String? firstName;
|
||||
final String? lastName;
|
||||
final String? photoUrl;
|
||||
final String? languageCode;
|
||||
}
|
||||
|
||||
enum PlaceTrait {
|
||||
calm,
|
||||
dynamic,
|
||||
|
||||
Reference in New Issue
Block a user