mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
faster account skip startup
This commit is contained in:
parent
65313b4579
commit
8b73c35e43
1 changed files with 9 additions and 8 deletions
|
@ -22,6 +22,15 @@ class AccountSelectActivity : AppCompatActivity() {
|
|||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
val accounts = getAccounts(this@AccountSelectActivity)
|
||||
|
||||
// Don't show account selection if there is only
|
||||
// one account that exists
|
||||
if (accounts.count() <= 1) {
|
||||
navigateToMainActivity()
|
||||
return
|
||||
}
|
||||
|
||||
CommonActivity.init(this)
|
||||
loadThemes(this)
|
||||
|
||||
|
@ -35,14 +44,6 @@ class AccountSelectActivity : AppCompatActivity() {
|
|||
|
||||
val recyclerView: RecyclerView = binding.root.findViewById(R.id.account_recycler_view)
|
||||
|
||||
val accounts = getAccounts(this@AccountSelectActivity)
|
||||
|
||||
// Don't show account selection if there is only
|
||||
// one account that exists
|
||||
if (accounts.count() <= 1) {
|
||||
navigateToMainActivity()
|
||||
return
|
||||
}
|
||||
|
||||
val adapter = AccountAdapter(accounts) { selectedAccount ->
|
||||
// Handle the selected account
|
||||
|
|
Loading…
Reference in a new issue