diff --git a/Telegram/SourceFiles/calls/group/calls_group_call.cpp b/Telegram/SourceFiles/calls/group/calls_group_call.cpp index 09fb828dc1..c1ee3c2348 100644 --- a/Telegram/SourceFiles/calls/group/calls_group_call.cpp +++ b/Telegram/SourceFiles/calls/group/calls_group_call.cpp @@ -1065,6 +1065,7 @@ void GroupCall::start(TimeId scheduleDate, bool rtmp) { MTPstring(), // title MTP_int(scheduleDate) )).done([=](const MTPUpdates &result) { + _reloadedStaleCall = true; _acceptFields = true; _peer->session().api().applyUpdates(result); _acceptFields = false; @@ -1393,6 +1394,13 @@ void GroupCall::rejoin(not_null as) { sendSelfUpdate(SendUpdateType::CameraPaused); } sendPendingSelfUpdates(); + if (!_reloadedStaleCall + && _state.current() != State::Joining) { + if (const auto real = lookupReal()) { + _reloadedStaleCall = true; + real->reloadIfStale(); + } + } }).fail([=](const MTP::Error &error) { _joinState.finish(); diff --git a/Telegram/SourceFiles/calls/group/calls_group_call.h b/Telegram/SourceFiles/calls/group/calls_group_call.h index 6f363c1c2e..8b8eb34ca5 100644 --- a/Telegram/SourceFiles/calls/group/calls_group_call.h +++ b/Telegram/SourceFiles/calls/group/calls_group_call.h @@ -674,6 +674,7 @@ private: bool _hadJoinedState = false; bool _listenersHidden = false; bool _rtmp = false; + bool _reloadedStaleCall = false; int _rtmpVolume = 0; std::unique_ptr _mediaDevices;