remove confusing messages when Privileged Extension not installed
This was saying that the Privileged Extension is enabled but not properly configured. This is because the preference logic changed to default to on unless the user explicitly disabled it. So using the Privileged Extension based on whether its installed and whether the user has disabled it. related to ea0700d406101b7ed6907b1dbd2918dbc214f435
This commit is contained in:
parent
2d25ef53f5
commit
1d5dcb76a2
@ -20,7 +20,6 @@
|
||||
package org.fdroid.fdroid.installer;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
|
||||
import org.fdroid.fdroid.Preferences;
|
||||
import org.fdroid.fdroid.Utils;
|
||||
@ -47,17 +46,11 @@ public class InstallerFactory {
|
||||
&& apk.packageName.equals(PrivilegedInstaller.PRIVILEGED_EXTENSION_PACKAGE_NAME)) {
|
||||
// special case for "F-Droid Privileged Extension"
|
||||
installer = new ExtensionInstaller(context);
|
||||
} else if (isPrivilegedInstallerEnabled()) {
|
||||
if (PrivilegedInstaller.isExtensionInstalledCorrectly(context)
|
||||
} else if (isPrivilegedInstallerEnabled()
|
||||
&& PrivilegedInstaller.isExtensionInstalledCorrectly(context)
|
||||
== PrivilegedInstaller.IS_EXTENSION_INSTALLED_YES) {
|
||||
Utils.debugLog(TAG, "privileged extension correctly installed -> PrivilegedInstaller");
|
||||
|
||||
installer = new PrivilegedInstaller(context);
|
||||
} else {
|
||||
Log.e(TAG, "PrivilegedInstaller is enabled in prefs, but not working correctly!");
|
||||
// fallback to default installer
|
||||
installer = new DefaultInstaller(context);
|
||||
}
|
||||
} else {
|
||||
installer = new DefaultInstaller(context);
|
||||
}
|
||||
|
@ -271,7 +271,6 @@ public class PrivilegedInstaller extends Installer {
|
||||
public static int isExtensionInstalledCorrectly(Context context) {
|
||||
// check if installed
|
||||
if (!isExtensionInstalled(context)) {
|
||||
Log.e(TAG, "IS_EXTENSION_INSTALLED_NO");
|
||||
return IS_EXTENSION_INSTALLED_NO;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user