Clear directly-deleted local photos from cache.

This commit is contained in:
John Preston
2026-08-14 11:16:58 +04:00
parent 10988300fd
commit e2bc4cef5b
14 changed files with 366 additions and 99 deletions

View File

@@ -3177,7 +3177,7 @@ void SessionController::cancelUploadLayer(not_null<HistoryItem*> item) {
if (const auto item = data.message(itemId)) {
if (!item->isEditingMedia()) {
const auto history = item->history();
item->destroy();
data.destroyMessageWithCacheCleanup(item);
history->requestChatListMessage();
} else {
item->returnSavedMedia();