Commit 332350cf authored by Mohit Mali's avatar Mohit Mali
Browse files

Change variable name

parent a60f8069
Pipeline #101181 passed with stage
in 4 minutes and 25 seconds
......@@ -138,21 +138,21 @@ class Installer(private val packageName: String,
}
private var receiver = object : BroadcastReceiver() {
override fun onReceive(p0: Context, p1: Intent) {
if (p1.action == Intent.ACTION_PACKAGE_ADDED &&
(p1.data.encodedSchemeSpecificPart == packageName)) {
override fun onReceive(context: Context, intent: Intent) {
if (intent.action == Intent.ACTION_PACKAGE_ADDED &&
(intent.data.encodedSchemeSpecificPart == packageName)) {
Log.i(TAG, "Broadcast received")
var path = apk.absolutePath.split("Download")
//delete all APK file after install
deleteFileOrDir(path[0] + "Download");
callback.onInstallationComplete(p0)
callback.onInstallationComplete(context)
if (packageName == Constants.MICROG_PACKAGE) {
if (PreferenceStorage(p0).getBoolean(p0.getString(R.string.prefs_microg_vrsn_installed),false)){
PreferenceStorage(p0).save(p0.getString(R.string.prefs_microg_vrsn_installed), false)
if (PreferenceStorage(context).getBoolean(context.getString(R.string.prefs_microg_vrsn_installed),false)){
PreferenceStorage(context).save(context.getString(R.string.prefs_microg_vrsn_installed), false)
}else{
PreferenceStorage(p0).save(p0.getString(R.string.prefs_microg_vrsn_installed), true)
PreferenceStorage(context).save(context.getString(R.string.prefs_microg_vrsn_installed), true)
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment