Skip to content

Commit d3b7f3e

Browse files
committed
fix: null-safe unboxing for photoEntry.highQuality
1 parent c944161 commit d3b7f3e

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

TMessagesProj/src/main/java/org/telegram/ui/ChatActivity.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20407,7 +20407,7 @@ private void sendPhotosGroup(ArrayList<MediaController.PhotoEntry> entries, bool
2040720407
SendMessagesHelper.SendingMediaInfo info = new SendMessagesHelper.SendingMediaInfo();
2040820408
if (!entry.isVideo && entry.imagePath != null) {
2040920409
info.path = entry.imagePath;
20410-
if (entry.highQuality) {
20410+
if (entry.isHighQuality()) {
2041120411
info.originalPhotoEntry = entry.clone();
2041220412
}
2041320413
} else if (entry.path != null) {
@@ -20427,7 +20427,7 @@ private void sendPhotosGroup(ArrayList<MediaController.PhotoEntry> entries, bool
2042720427
info.videoEditedInfo = entry.editedInfo;
2042820428
info.canDeleteAfter = entry.canDeleteAfter;
2042920429
info.hasMediaSpoilers = entry.hasSpoiler;
20430-
info.highQuality = entry.editedInfo == null && entry.highQuality;
20430+
info.highQuality = entry.isHighQuality();
2043120431
photos.add(info);
2043220432
entry.reset();
2043320433
}

TMessagesProj/src/main/java/org/telegram/ui/Components/ChatActivityEnterView.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5929,7 +5929,7 @@ public void sendButtonPressed(int index, VideoEditedInfo videoEditedInfo, boolea
59295929
SendMessagesHelper.SendingMediaInfo info = new SendMessagesHelper.SendingMediaInfo();
59305930
if (!photoEntry.isVideo && photoEntry.imagePath != null) {
59315931
info.path = photoEntry.imagePath;
5932-
if (photoEntry.highQuality) {
5932+
if (photoEntry.isHighQuality()) {
59335933
info.originalPhotoEntry = photoEntry.clone();
59345934
}
59355935
} else if (photoEntry.path != null) {
@@ -5948,7 +5948,7 @@ public void sendButtonPressed(int index, VideoEditedInfo videoEditedInfo, boolea
59485948
info.videoEditedInfo = videoEditedInfo;
59495949
info.canDeleteAfter = true;
59505950
info.hasMediaSpoilers = photoEntry.hasSpoiler;
5951-
info.highQuality = photoEntry.editedInfo == null && Boolean.TRUE.equals(photoEntry.highQuality);
5951+
info.highQuality = photoEntry.isHighQuality();
59525952
photos.add(info);
59535953
photoEntry.reset();
59545954
sending = true;

0 commit comments

Comments
 (0)