Skip to content

Commit

Permalink
fix(app): add misconfiguration warning for missing native module
Browse files Browse the repository at this point in the history
  • Loading branch information
mikehardy committed Oct 31, 2024
1 parent d55e891 commit 94a375c
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/app/lib/internal/RNFBNativeEventEmitter.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,13 @@ import { getReactNativeModule } from './nativeModule';

class RNFBNativeEventEmitter extends NativeEventEmitter {
constructor() {
super(getReactNativeModule('RNFBAppModule'));
const RNFBAppModule = getReactNativeModule('RNFBAppModule');
if (!RNFBAppModule) {
throw new Error(

Check warning on line 25 in packages/app/lib/internal/RNFBNativeEventEmitter.js

View check run for this annotation

Codecov / codecov/patch

packages/app/lib/internal/RNFBNativeEventEmitter.js#L25

Added line #L25 was not covered by tests
'Native module RNFBAppModule not found. Re-check module install, linking, configuration, build and install steps.',
);
}
super(RNFBAppModule);
this.ready = false;
}

Expand Down

0 comments on commit 94a375c

Please sign in to comment.