|
@@ -56,8 +56,9 @@ class ReactNativePermissions {
|
56
|
56
|
return RNPTypes[Platform.OS];
|
57
|
57
|
}
|
58
|
58
|
|
|
59
|
+
|
59
|
60
|
getPermissionStatus(permission) {
|
60
|
|
- if (this.getPermissionTypes().includes(permission)) {
|
|
61
|
+ if (RNPTypes.indexOf(permission) >= 0) {
|
61
|
62
|
return RNPermissions.getPermissionStatus(permission)
|
62
|
63
|
} else {
|
63
|
64
|
return Promise.reject(`ReactNativePermissions: ${permission} is not a valid permission type on ${Platform.OS}`)
|
|
@@ -106,4 +107,4 @@ class ReactNativePermissions {
|
106
|
107
|
}
|
107
|
108
|
}
|
108
|
109
|
|
109
|
|
-module.exports = new ReactNativePermissions()
|
|
110
|
+module.exports = new ReactNativePermissions()
|