Hello!
I keep getting this error when calling checkMultiplePermissions(['camera', 'photo']) on iOS. I added the library(the app is built correctly), added the descriptions to this permissions, nothing helps. Can you advise anything?

Do you have the same problem requesting a single permissions? can you share a screenshot of your linked frameworks and your import statement?
@iegik - do you mean that those changes are causing the same error for you? which version of RN and which version of this lib are you running?
RN 39 https://github.com/facebook/react-native/wiki/Breaking-Changes#040
Namespace all header imports to
Always keep backwards-compatible PATCH version! http://semver.org/
Yes, this change locally fixes the issue
вс, 12 февр. 2017 г. в 17:40, Arturs Jansons notifications@github.com:
RN 39 https://github.com/facebook/react-native/wiki/Breaking-Changes#040
Namespace all header imports to
Always keep backwards-compatible PATCH version! http://semver.org/
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/yonahforst/react-native-permissions/issues/73#issuecomment-279222871,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABJASmcw33pxKosAhr8jO3ZyaclGbXOkks5rbxnvgaJpZM4L4R05
.
@iegik - thanks. I'll try to stick to semver going forward. You should be OK if you go back down to version 0.2.5
Hey, I am getting the same error.
React native - 0.38
Library - 0.2.5
I am also getting the same error:
RN - 0.42.3
Library - 0.2.7
I'm still getting this issue with various different versions mentioned above.
I have a blank project with just a webview and react-native-permissions.
Please provide what versions of libraries I should be using?
Thanks
check if stuffs are linked properly on both android and ios. You can compare from the example provided.
Hi @roshangm1 thanks for the reply. Yes I have run rnpm link and also manually done Android manual linking in Readme.md but still get that error regardless of what versions I try (I've tried a lot!).
Thanks for suggesting trying the example. I tried that and get the error:
ctNativePermissionsModule.java:63: error: cannot find symbol
if (mNotificationManagerCompat.areNotificationsEnabled()) {
^
symbol: method areNotificationsEnabled()
location: variable mNotificationManagerCompat of type NotificationManagerCompat
1 error
@andrewhine-gat - are you building from master? try deleting from node_modules and reinstalling from npm
@andrewhine-gat - or you can try updating the compileSdkVersion in your app gradle to 24
http://stackoverflow.com/questions/38016215/android-notificationmanagercompat-arenotificationsenabled-not-working
@yonahforst Thanks for fast reply.
I also found that same link and tried upgrading to 24 but same error above.
I'm doing:
git clone https://github.com/yonahforst/react-native-permissions.git
cd react-native-permissions/Example
npm install
Change android/app/build.gradle to
compileSdkVersion 24
buildToolsVersion "24.0.0"
and
dependencies {
compile 'com.android.support:support-v4:24.0.0'
}
react-native run-android
I just tried again in a fresh folder and got the same error.
Thanks in advance.
Editing react-native-permissions/Example/node_modules/react-native-permissions/android/build.gradle
to
android {
compileSdkVersion 24
buildToolsVersion "25.0.2"
defaultConfig {
minSdkVersion 24
targetSdkVersion 24
versionCode 2
versionName "1.1"
}
...
dependencies {
compile 'com.facebook.react:react-native:+'
compile 'com.android.support:support-v4:24.0.0'
}
Gets the Example running.
Having played around with your Example, I think it may not be possible to do what I'm trying to do:
I'm trying to access the device's camera from a webview within the react native app using the HTML5 camera input type (I'm using https://davidwalsh.name/demo/camera.php as a test).
I added a Webview to your working Example but even after requesting and granting camera permissions, the camera in the above website appears as a play button image graphic (and the same in Genymotion).
@yonahforst do you know if it is possible to get this working using your library?
Thanks in advance
I got the same error in android. Resolved after linking properly
these things were missing after rnpm link
* MainApplication.java*
import com.joshblour.reactnativepermissions.ReactNativePermissionsPackage;
new ReactNativePermissionsPackage()
Hey guys, I have the same error after running the link command
react-native link react-native-permissions
Could I know how to fix this error? I am receiving the error on iOS itself.
facing same issue in iOS with 0.2.5 and 0.2.7 on RN 0.44.0, should it be reopened?
I did add permission description as described on readme.
any idea on how to fix that on iOS guys?
thx!
Just want to mention what happened to me, and that was simply forgetting to run react-native link after installing
Just ran into this issue on react-native 0.51.
I followed the instructions and ran react-native link react-native-permissions, but was still getting this error.
Here is what worked for me:
Go into your ios folder and run pod install. At first, this produced another error for me because I had React defined twice. To use the React from your node_modules, add the following to your Podfile
pod "yoga", :path => "../node_modules/react-native/ReactCommon/yoga"
pod 'React', :path => '../node_modules/react-native', :subspecs => [
'BatchedBridge', # Required For React Native 0.45.0+
'Core',
# Add any other subspecs you want to use in your project
]
After this, run pod install again, and then build-ios.
This solved all issues for me.
I also have this problem. Can anyone help?
I also ran into this issue, react-native link react-native-permissions gave a positive response but the link didn't work.
What solved it for me was to add the link manually.
Using manual linking
In the XCode's "Project navigator", right click on your project's Libraries folder ➜ Add Files to <...>
Go to node_modules ➜ react-native-permissions ➜ select ReactNativePermissions.xcodeproj
Add libReactNativePermissions.a to Build Phases -> Link Binary With Libraries
I also ran into this issue,
react-native link react-native-permissionsgave a positive response but the link didn't work.
What solved it for me was to add the link manually.Using manual linking
In the XCode's "Project navigator", right click on your project's Libraries folder ➜ Add Files to <...>
Go to node_modules ➜ react-native-permissions ➜ select ReactNativePermissions.xcodeproj
Add libReactNativePermissions.a to Build Phases -> Link Binary With Libraries
Thank you. It's work.
Most helpful comment
I also ran into this issue,
react-native link react-native-permissionsgave a positive response but the link didn't work.What solved it for me was to add the link manually.
Using manual linking
In the XCode's "Project navigator", right click on your project's Libraries folder ➜ Add Files to <...>
Go to node_modules ➜ react-native-permissions ➜ select ReactNativePermissions.xcodeproj
Add libReactNativePermissions.a to Build Phases -> Link Binary With Libraries