Skip to content

Commit

Permalink
fix(crashlytics): internally use modular APIs during initialization
Browse files Browse the repository at this point in the history
this avoids deprecation warnings from popping up despite users during
their best to adopt the modular APIs
  • Loading branch information
mikehardy committed Feb 9, 2025
1 parent fb679f0 commit d3e3ddc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/crashlytics/lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,14 @@
*
*/

import { getApp } from '@react-native-firebase/app';
import {
isBoolean,
isError,
isObject,
isString,
isOther,
MODULAR_DEPRECATION_ARG,
} from '@react-native-firebase/app/lib/common';
import {
createModuleNamespace,
Expand Down Expand Up @@ -171,5 +173,5 @@ export const firebase = getFirebaseRoot();

// This will throw with 'Default App Not initialized' if the default app is not configured.
if (!isOther) {
firebase.crashlytics();
firebase.crashlytics.call(null, getApp(), MODULAR_DEPRECATION_ARG);
}

0 comments on commit d3e3ddc

Please sign in to comment.