2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-17 15:26:23 +00:00
This commit is contained in:
Gabriel Luong 2021-01-05 16:59:41 -05:00 committed by GitHub
parent 4e1f40b41b
commit 9a60af122f

View File

@ -321,12 +321,9 @@ class DefaultSessionControlController(
setTitle(R.string.rename_top_site)
setView(customLayout)
setPositiveButton(R.string.top_sites_rename_dialog_ok) { dialog, _ ->
val newTitle = topSiteLabelEditText.text.toString()
if (newTitle.isNotBlank()) {
viewLifecycleScope.launch(Dispatchers.IO) {
with(activity.components.useCases.topSitesUseCase) {
renameTopSites(topSite, newTitle)
}
viewLifecycleScope.launch(Dispatchers.IO) {
with(activity.components.useCases.topSitesUseCase) {
renameTopSites(topSite, topSiteLabelEditText.text.toString())
}
}
dialog.dismiss()