CameraManager: Swap propertyName / packageName in call to getProperty()

propertyName should be the first argument, not packageName.

Bug: 272595790
Test: Added manifest property to sample app, trying all combinations
Change-Id: Ida07d367a265f1bd703461dfbedc08f6cdeaba50
This commit is contained in:
Austin Borger
2023-03-09 16:23:29 -08:00
parent 0011ba7e1c
commit 12c74fb190

View File

@@ -1189,8 +1189,8 @@ public final class CameraManager {
PackageManager packageManager = context.getPackageManager();
try {
return packageManager.getProperty(context.getOpPackageName(),
PROPERTY_COMPAT_OVERRIDE_LANDSCAPE_TO_PORTRAIT).getBoolean();
return packageManager.getProperty(PROPERTY_COMPAT_OVERRIDE_LANDSCAPE_TO_PORTRAIT,
context.getOpPackageName()).getBoolean();
} catch (PackageManager.NameNotFoundException e) {
// No such property
}