flutter-permission-plugins
flutter-permission-plugins copied to clipboard
Unable to compile in my app
🐛 Bug Report
Can't add this to my app. I am using the latest build. When I download the source and build that separately everything works fine and compiles and runs but not in my android app.
^
symbol: variable ACCESS_BACKGROUND_LOCATION location: class permission F:\flutter.pub-cache\hosted\pub.dartlang.org\location_permissions-2.0.5\android\src\main\java\com\baseflow\location_permissions\LocationPermissionsPlugin.java:310: error: cannot find symbol if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q && hasPermissionInManifest(Manifest.permission.ACCESS_BACKGROUND_LOCATION, context)) { ^ symbol: variable Q location: class VERSION_CODES F:\flutter.pub-cache\hosted\pub.dartlang.org\location_permissions-2.0.5\android\src\main\java\com\baseflow\location_permissions\LocationPermissionsPlugin.java:310: error: cannot find symbol if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q && hasPermissionInManifest(Manifest.permission.ACCESS_BACKGROUND_LOCATION, context)) { ^ symbol: variable ACCESS_BACKGROUND_LOCATION location: class permission F:\flutter.pub-cache\hosted\pub.dartlang.org\location_permissions-2.0.5\android\src\main\java\com\baseflow\location_permissions\LocationPermissionsPlugin.java:311: error: cannot find symbol permissionNames.add(Manifest.permission.ACCESS_BACKGROUND_LOCATION); ^ symbol: variable ACCESS_BACKGROUND_LOCATION location: class permission 5 errors
FAILURE: Build failed with an exception.
Expected behavior
Reproduction steps
Configuration
Version: 2.0.5
build.gradle is set to compileSdkVersion 29 and I'm using AndroidX so should not be a problem.
Platform: Android
change compileSdkVersion to 29, it will compile for you