mayo-firebase-config 1.2.14 → 1.2.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -17,9 +17,9 @@ Use the extractFirebaseConfig function in your React Native code as follows:
17
17
 
18
18
  ```javascript
19
19
 
20
- import { extractFirebaseConfig } from 'mayo-firebase-config';
20
+ import { extractConfig } from 'mayo-firebase-config';
21
21
 
22
- const firebaseConfig = await extractFirebaseConfig();
22
+ const firebaseConfig = await extractConfig();
23
23
  console.log(firebaseConfig);
24
24
 
25
25
  ```
@@ -33,7 +33,7 @@ public class FirebaseConfigExtractorModule extends ReactContextBaseJavaModule {
33
33
  }
34
34
 
35
35
  @ReactMethod
36
- public void extractFirebaseConfig(Promise promise) {
36
+ public void extractConfig(Promise promise) {
37
37
  Log.d(NAME, "Starting to extract Firebase config.");
38
38
  try {
39
39
  // Use AssetManager to read the google-services.json file from the assets folder
@@ -9,11 +9,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  });
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.extractFirebaseConfig = void 0;
12
+ exports.extractConfig = void 0;
13
13
  const react_native_1 = require("react-native");
14
14
  const mayo_logger_1 = require("mayo-logger");
15
15
  const { FirebaseConfigExtractor } = react_native_1.NativeModules;
16
- const extractFirebaseConfig = () => __awaiter(void 0, void 0, void 0, function* () {
16
+ const extractConfig = () => __awaiter(void 0, void 0, void 0, function* () {
17
17
  try {
18
18
  mayo_logger_1.Logger.info('Starting Firebase config extraction...', null, { tag: 'mayo-firebase-config-extractor' });
19
19
  const config = yield FirebaseConfigExtractor.extractConfig();
@@ -24,7 +24,7 @@ const extractFirebaseConfig = () => __awaiter(void 0, void 0, void 0, function*
24
24
  mayo_logger_1.Logger.warn('Failed to extract valid Firebase config or the config is empty', null, { tag: 'mayo-firebase-config-extractor' });
25
25
  }
26
26
  // Be cautious about logging potentially sensitive information
27
- mayo_logger_1.Logger.error('Extracted Firebase config:', { config }, { tag: 'mayo-firebase-config-extractor' });
27
+ mayo_logger_1.Logger.info('Extracted Firebase config:', { config }, { tag: 'mayo-firebase-config-extractor' });
28
28
  return config;
29
29
  }
30
30
  catch (error) {
@@ -33,4 +33,4 @@ const extractFirebaseConfig = () => __awaiter(void 0, void 0, void 0, function*
33
33
  throw error;
34
34
  }
35
35
  });
36
- exports.extractFirebaseConfig = extractFirebaseConfig;
36
+ exports.extractConfig = extractConfig;
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.extractFirebaseConfig = void 0;
3
+ exports.extractConfig = void 0;
4
4
  var extractFirebaseConfig_1 = require("./extractFirebaseConfig");
5
- Object.defineProperty(exports, "extractFirebaseConfig", { enumerable: true, get: function () { return extractFirebaseConfig_1.extractFirebaseConfig; } });
5
+ Object.defineProperty(exports, "extractConfig", { enumerable: true, get: function () { return extractFirebaseConfig_1.extractConfig; } });
package/index.d.ts CHANGED
@@ -12,5 +12,5 @@ declare module 'mayo-firebase-config' {
12
12
  [key: string]: string | undefined;
13
13
  }
14
14
 
15
- export function extractFirebaseConfig(): Promise<FirebaseConfig>;
15
+ export function extractConfig(): Promise<FirebaseConfig>;
16
16
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mayo-firebase-config",
3
- "version": "1.2.14",
3
+ "version": "1.2.16",
4
4
  "license": "MIT",
5
5
  "author": "Mohamed Bennekrouf",
6
6
  "main": "dist/index.js",
@@ -4,7 +4,7 @@ import { FirebaseConfig } from 'mayo-firebase-config';
4
4
 
5
5
  const { FirebaseConfigExtractor } = NativeModules;
6
6
 
7
- export const extractFirebaseConfig = async (): Promise<FirebaseConfig> => {
7
+ export const extractConfig = async (): Promise<FirebaseConfig> => {
8
8
  try {
9
9
  Logger.info('Starting Firebase config extraction...', null, { tag: 'mayo-firebase-config-extractor' });
10
10
 
package/src/index.ts CHANGED
@@ -1 +1 @@
1
- export { extractFirebaseConfig } from './extractFirebaseConfig';
1
+ export { extractConfig } from './extractFirebaseConfig';