From c8b828bfe19a76110e72af47a1b438b5561337bc Mon Sep 17 00:00:00 2001 From: Username1548 Date: Fri, 25 Apr 2025 19:10:08 +0700 Subject: [PATCH] fix(profile): profile subs fixed --- lib/features/profile/models/profile_model.dart | 4 ++-- lib/features/profile/presentation/pages/profile_screen.dart | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/features/profile/models/profile_model.dart b/lib/features/profile/models/profile_model.dart index 9d4e877f..6aeb1767 100644 --- a/lib/features/profile/models/profile_model.dart +++ b/lib/features/profile/models/profile_model.dart @@ -21,8 +21,8 @@ class ProfileModel with _$ProfileModel { @JsonKey(name: "profile_photo_url") required String profilePhotoUrl, @JsonKey(name: "roles") required List roles, @JsonKey(name: "badges") required List badges, - @JsonKey(name: "subscriptions") required List subscriptions, - @JsonKey(name: "subscribers") required List subscribers, + @JsonKey(name: "subscriptions") required List subscriptions, + @JsonKey(name: "subscribers") required List subscribers, @JsonKey(name: "education_resource") EducationModel? educationResource, @JsonKey(name: "cert_photos") List? diplomasAndCertificates, }) = _ProfileModel; diff --git a/lib/features/profile/presentation/pages/profile_screen.dart b/lib/features/profile/presentation/pages/profile_screen.dart index 12e4c4ea..2acd9bac 100644 --- a/lib/features/profile/presentation/pages/profile_screen.dart +++ b/lib/features/profile/presentation/pages/profile_screen.dart @@ -728,7 +728,7 @@ class _ProfileScreenState extends State { ), Padding( padding: const EdgeInsets.only(right: 8), - child: _miniAvatars(state.profile.subscriptions.map((e) => e.profilePhotoUrl).toList()), + child: _miniAvatars(state.profile.subscriptions), ), ], ), @@ -778,7 +778,7 @@ class _ProfileScreenState extends State { ), Padding( padding: const EdgeInsets.only(right: 8), - child: _miniAvatars(state.profile.subscribers.map((e) => e.profilePhotoUrl).toList()), + child: _miniAvatars(state.profile.subscribers), ), ], ),