[mob][photos] Use genId + uploadedId instead of just genId for value key to make sure all keys are unique when opening a public link in-app (genID is null for all files in public link)

This commit is contained in:
ashilkn 2024-12-24 16:30:38 +05:30
parent df68d3f005
commit cc674183cd

View File

@ -27,7 +27,9 @@ class FileWidget extends StatelessWidget {
Widget build(BuildContext context) {
// Specify key to ensure that the widget is rebuilt when the file changes
// Before changing this, ensure that file deletes are handled properly
final String fileKey = "file_${file.generatedID}";
final String fileKey =
"file_genID_${file.generatedID}___file_id_${file.uploadedFileID}";
if (file.fileType == FileType.livePhoto ||
file.fileType == FileType.image) {
return ZoomableLiveImageNew(