mirror of
https://github.com/Corewala/Buran
synced 2025-01-02 21:24:19 +00:00
Simplified request function
This commit is contained in:
parent
20846dad47
commit
4808620743
1 changed files with 3 additions and 5 deletions
|
@ -754,16 +754,14 @@ class GemActivity : AppCompatActivity() {
|
|||
}
|
||||
|
||||
private fun request(address: String){
|
||||
val certPassword = if((address.toURI().host == omniTerm.getCurrent().toURI().host)){
|
||||
decryptedCertPassword
|
||||
}else{
|
||||
null
|
||||
if(address.toURI().host != omniTerm.getCurrent().toURI().host) {
|
||||
decryptedCertPassword = null
|
||||
}
|
||||
|
||||
if(getInternetStatus()){
|
||||
if(initialised){
|
||||
loadingView(true)
|
||||
return model.request(address, certPassword)
|
||||
return model.request(address, decryptedCertPassword)
|
||||
}else{
|
||||
val intent = baseContext.packageManager.getLaunchIntentForPackage(baseContext.packageName)
|
||||
intent!!.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP)
|
||||
|
|
Loading…
Reference in a new issue