mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
Added MEDIA_NEW_INVALID error handler. Disabled edit media with webp.
This commit is contained in:
@@ -4644,7 +4644,8 @@ void ApiWrap::editUploadedPhoto(
|
||||
applyUpdates(result);
|
||||
}).fail([=](const RPCError &error) {
|
||||
QString err = error.type();
|
||||
if (err == qstr("MESSAGE_NOT_MODIFIED")) {
|
||||
if (err == qstr("MESSAGE_NOT_MODIFIED")
|
||||
|| err == qstr("MEDIA_NEW_INVALID")) {
|
||||
item->returnSavedMedia();
|
||||
_session->data().sendHistoryChangeNotifications();
|
||||
} else {
|
||||
@@ -4707,7 +4708,8 @@ void ApiWrap::editUploadedDocument(
|
||||
applyUpdates(result);
|
||||
}).fail([=](const RPCError &error) {
|
||||
QString err = error.type();
|
||||
if (err == qstr("MESSAGE_NOT_MODIFIED")) {
|
||||
if (err == qstr("MESSAGE_NOT_MODIFIED")
|
||||
|| err == qstr("MEDIA_NEW_INVALID")) {
|
||||
item->returnSavedMedia();
|
||||
_session->data().sendHistoryChangeNotifications();
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user