Skip to content

Commit

Permalink
[mob][photos] Fix null check used in null value error
Browse files Browse the repository at this point in the history
  • Loading branch information
ashilkn committed Nov 21, 2024
1 parent 5056977 commit 8c36fdb
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,11 @@ class GalleryFileWidget extends StatelessWidget {
@override
Widget build(BuildContext context) {
final isFileSelected = selectedFiles?.isFileSelected(file) ?? false;
final isPublicFile =
CollectionsService.instance.isPublicCollection(file.collectionID!);
bool isPublicFile = false;
if (file.collectionID != null) {
isPublicFile =
CollectionsService.instance.isPublicCollection(file.collectionID!);
}
Color selectionColor = Colors.white;
if (isFileSelected && file.isUploaded && file.ownerID != currentUserID) {
final avatarColors = getEnteColorScheme(context).avatarColors;
Expand Down

0 comments on commit 8c36fdb

Please sign in to comment.