1
1
package io .fullstack .firestack ;
2
2
3
- import android .content .Context ;
4
- import android .util .Log ;
5
3
import java .util .Map ;
6
- import android .support .annotation .NonNull ;
4
+ import android .util .Log ;
5
+ import android .content .Context ;
7
6
import android .support .annotation .Nullable ;
8
7
9
8
import com .facebook .react .bridge .Arguments ;
14
13
import com .facebook .react .bridge .Callback ;
15
14
import com .facebook .react .bridge .WritableMap ;
16
15
import com .facebook .react .bridge .ReadableMap ;
17
- import com .facebook .react .modules .core .DeviceEventManagerModule ;
18
16
import com .facebook .react .bridge .ReactContext ;
19
17
20
- import com .google .android .gms .tasks .OnCompleteListener ;
21
- import com .google .android .gms .tasks .OnFailureListener ;
22
- import com .google .android .gms .tasks .Task ;
23
18
import com .google .firebase .FirebaseApp ;
24
19
import com .google .firebase .FirebaseOptions ;
25
20
import com .google .firebase .database .ServerValue ;
@@ -76,43 +71,43 @@ public String setKeyOrDefault(
76
71
}
77
72
};
78
73
79
- String val = fn .setKeyOrDefault ("applicationId" ,
74
+ String val = fn .setKeyOrDefault ("applicationId" ,
80
75
defaultOptions .getApplicationId ());
81
76
if (val != null ) {
82
77
builder .setApplicationId (val );
83
78
}
84
79
85
- val = fn .setKeyOrDefault ("apiKey" ,
80
+ val = fn .setKeyOrDefault ("apiKey" ,
86
81
defaultOptions .getApiKey ());
87
82
if (val != null ) {
88
83
builder .setApiKey (val );
89
84
}
90
85
91
- val = fn .setKeyOrDefault ("gcmSenderID" ,
86
+ val = fn .setKeyOrDefault ("gcmSenderID" ,
92
87
defaultOptions .getGcmSenderId ());
93
88
if (val != null ) {
94
89
builder .setGcmSenderId (val );
95
90
}
96
91
97
- val = fn .setKeyOrDefault ("storageBucket" ,
92
+ val = fn .setKeyOrDefault ("storageBucket" ,
98
93
defaultOptions .getStorageBucket ());
99
94
if (val != null ) {
100
95
builder .setStorageBucket (val );
101
96
}
102
97
103
- val = fn .setKeyOrDefault ("databaseURL" ,
98
+ val = fn .setKeyOrDefault ("databaseURL" ,
104
99
defaultOptions .getDatabaseUrl ());
105
100
if (val != null ) {
106
101
builder .setDatabaseUrl (val );
107
102
}
108
103
109
- val = fn .setKeyOrDefault ("databaseUrl" ,
104
+ val = fn .setKeyOrDefault ("databaseUrl" ,
110
105
defaultOptions .getDatabaseUrl ());
111
106
if (val != null ) {
112
107
builder .setDatabaseUrl (val );
113
108
}
114
109
115
- val = fn .setKeyOrDefault ("clientId" ,
110
+ val = fn .setKeyOrDefault ("clientId" ,
116
111
defaultOptions .getApplicationId ());
117
112
if (val != null ) {
118
113
builder .setApplicationId (val );
@@ -208,4 +203,4 @@ public void onHostPause() {
208
203
public void onHostDestroy () {
209
204
210
205
}
211
- }
206
+ }
0 commit comments