Skip to content

Commit

Permalink
Fix crash in video messages playback.
Browse files Browse the repository at this point in the history
Regression was introduced in ad3e447.
  • Loading branch information
john-preston committed Aug 29, 2024
1 parent ed342ee commit 9252be5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Telegram/SourceFiles/media/player/media_player_widget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -670,15 +670,15 @@ void Widget::updateTimeLabel() {
void Widget::handleSongChange() {
const auto current = instance()->current(_type);
const auto document = current.audio();
_lastSongFromAnotherSession = (document->session().uniqueId()
!= _controller->session().uniqueId());
if (!current
|| !document
|| ((_lastSongId.audio() == document)
&& (_lastSongId.contextId() == current.contextId()))) {
return;
}
_lastSongId = current;
_lastSongFromAnotherSession = (document->session().uniqueId()
!= _controller->session().uniqueId());

auto textWithEntities = TextWithEntities();
if (document->isVoiceMessage() || document->isVideoMessage()) {
Expand Down

0 comments on commit 9252be5

Please sign in to comment.