2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Handle located groups as public.

This commit is contained in:
John Preston
2019-06-21 14:27:46 +02:00
parent 6537e524b8
commit 7d585ab72f
37 changed files with 468 additions and 275 deletions

View File

@@ -2885,14 +2885,13 @@ void Session::applyUpdate(const MTPDupdateChatDefaultBannedRights &update) {
}
}
not_null<LocationData*> Session::location(const LocationCoords &coords) {
auto i = _locations.find(coords);
if (i == _locations.cend()) {
i = _locations.emplace(
coords,
std::make_unique<LocationData>(coords)).first;
}
return i->second.get();
not_null<LocationThumbnail*> Session::location(const LocationPoint &point) {
const auto i = _locations.find(point);
return (i != _locations.cend())
? i->second.get()
: _locations.emplace(
point,
std::make_unique<LocationThumbnail>(point)).first->second.get();
}
void Session::registerPhotoItem(