Skip to content

Commit

Permalink
Small refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
bogdan-niculescu-sch committed Jul 12, 2022
1 parent 5079ebc commit 0a7435c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,9 @@ class AuthorizationManagementActivity : Activity() {
}

override fun onSaveInstanceState(outState: Bundle) {
super.onSaveInstanceState(outState)
outState.putBoolean(KEY_AUTHORIZATION_STARTED, authStarted)
outState.putParcelable(KEY_AUTH_INTENT, authIntent)
super.onSaveInstanceState(outState)
}

private fun handleAuthorizationComplete() {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package com.schibsted.account.webflows.client

import android.content.ActivityNotFoundException
import android.content.Context
import android.content.Intent
import android.net.Uri
Expand Down Expand Up @@ -103,7 +102,7 @@ class Client : ClientInterface {
intent.data = loginUrl
}.intent
} else {
Intent(Intent.ACTION_VIEW, loginUrl)
Intent(Intent.ACTION_VIEW, loginUrl).addCategory(Intent.CATEGORY_BROWSABLE)
}
return AuthorizationManagementActivity.createStartIntent(context, intent)
}
Expand All @@ -121,7 +120,7 @@ class Client : ClientInterface {
.build()
.launchUrl(context, loginUrl)
} else {
val intent = Intent(Intent.ACTION_VIEW, loginUrl)
val intent = Intent(Intent.ACTION_VIEW, loginUrl).addCategory(Intent.CATEGORY_BROWSABLE)
context.startActivity(intent)
}
}
Expand Down

0 comments on commit 0a7435c

Please sign in to comment.