remove unnecessary check in MyLocationTabFragment

This commit is contained in:
Chumva 2018-08-09 18:24:55 +03:00
parent 76fba24c4d
commit 6768fd0745

View file

@ -490,9 +490,7 @@ class MyLocationTabFragment : Fragment(), TelegramListener, ChatLiveMessagesList
setOnCheckedChangeListener { _, isChecked ->
if (!isChecked) {
app.settings.shareLocationToChat(chat.id, false)
if (!app.settings.hasAnyChatToShareLocation()) {
app.shareLocationHelper.stopSharingLocation()
}
app.shareLocationHelper.stopSharingLocation()
removeItem(chat)
}
}