mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-09-03 16:05:57 +00:00
Fixed MIME checking for files when edit media.
This commit is contained in:
@@ -343,11 +343,8 @@ void EditCaptionBox::updateEditPreview() {
|
|||||||
|
|
||||||
const auto fileinfo = QFileInfo(file->path);
|
const auto fileinfo = QFileInfo(file->path);
|
||||||
const auto filename = fileinfo.fileName();
|
const auto filename = fileinfo.fileName();
|
||||||
const auto mimeType = Core::MimeTypeForFile(fileinfo).name();
|
|
||||||
|
|
||||||
if (!file->path.isEmpty()) {
|
_isImage = fileIsImage(filename, file->mime);
|
||||||
_isImage = fileIsImage(filename, mimeType);
|
|
||||||
}
|
|
||||||
_isAudio = false;
|
_isAudio = false;
|
||||||
_animated = false;
|
_animated = false;
|
||||||
_photo = false;
|
_photo = false;
|
||||||
|
Reference in New Issue
Block a user