mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 06:26:18 +00:00
Fixed refreshing of file reference in api toggling media module.
This commit is contained in:
@@ -2332,6 +2332,9 @@ void ApiWrap::refreshFileReference(
|
||||
void ApiWrap::refreshFileReference(
|
||||
Data::FileOrigin origin,
|
||||
FileReferencesHandler &&handler) {
|
||||
const auto fail = [&] {
|
||||
handler(UpdatedFileReferences());
|
||||
};
|
||||
const auto request = [&](
|
||||
auto &&data,
|
||||
Fn<void()> &&additional = nullptr) {
|
||||
@@ -2349,9 +2352,6 @@ void ApiWrap::refreshFileReference(
|
||||
}
|
||||
}
|
||||
};
|
||||
const auto fail = [&] {
|
||||
handler(UpdatedFileReferences());
|
||||
};
|
||||
v::match(origin.data, [&](Data::FileOriginMessage data) {
|
||||
if (const auto item = _session->data().message(data)) {
|
||||
if (item->isScheduled()) {
|
||||
|
Reference in New Issue
Block a user