mirror of
https://github.com/telegramdesktop/tdesktop
synced 2024-12-29 01:52:48 +00:00
Fixed crash on pinning dialog from context menu.
Regression was introduced in 3a147305b7.
This commit is contained in:
parent
0824d2da20
commit
b49a8e6dc1
@ -306,6 +306,7 @@ void Filler::addHidePromotion() {
|
||||
}
|
||||
|
||||
void Filler::addTogglePin() {
|
||||
const auto controller = _controller;
|
||||
const auto filterId = _filterId;
|
||||
const auto peer = _peer;
|
||||
const auto history = peer->owner().history(peer);
|
||||
@ -315,7 +316,7 @@ void Filler::addTogglePin() {
|
||||
: tr::lng_context_pin_to_top(tr::now);
|
||||
};
|
||||
const auto pinToggle = [=] {
|
||||
TogglePinnedDialog(_controller, history, filterId);
|
||||
TogglePinnedDialog(controller, history, filterId);
|
||||
};
|
||||
const auto pinAction = _addAction(pinText(), pinToggle);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user