[js][firestore] added `enableLogging(boolean)` method

This commit is contained in:
Salakar 2017-11-28 07:41:55 +00:00
parent 11e5bc2ae7
commit 54e904e22f
1 changed files with 7 additions and 0 deletions

View File

@ -2,6 +2,8 @@
* @flow
* Firestore representation wrapper
*/
import { NativeModules } from 'react-native';
import ModuleBase from './../../utils/ModuleBase';
import CollectionReference from './CollectionReference';
import DocumentReference from './DocumentReference';
@ -141,4 +143,9 @@ export default class Firestore extends ModuleBase {
export const statics = {
FieldValue,
GeoPoint,
enableLogging(bool) {
if (NativeModules[Firestore._NATIVE_MODULE]) {
NativeModules[Firestore._NATIVE_MODULE].enableLogging(bool);
}
},
};