File tree Expand file tree Collapse file tree 6 files changed +15
-15
lines changed
android/src/main/java/com/margelo/rnquicksqlite Expand file tree Collapse file tree 6 files changed +15
-15
lines changed Original file line number Diff line number Diff line change 77import com .facebook .react .bridge .Promise ;
88import com .facebook .react .bridge .ReactApplicationContext ;
99
10- public class RNQuickSQLiteInitModule extends NativeRNQuickSQLiteInitSpec {
11- public RNQuickSQLiteInitModule (ReactApplicationContext reactContext ) {
10+ public class RNQuickSQLiteModule extends NativeRNQuickSQLiteModuleSpec {
11+ public RNQuickSQLiteModule (ReactApplicationContext reactContext ) {
1212 super (reactContext );
1313 }
1414
Original file line number Diff line number Diff line change @@ -21,8 +21,8 @@ public class RNQuickSQLitePackage extends TurboReactPackage {
2121 @ Nullable
2222 @ Override
2323 public NativeModule getModule (String name , ReactApplicationContext reactContext ) {
24- if (name .equals (RNQuickSQLiteInitModule .NAME )) {
25- return new RNQuickSQLiteInitModule (reactContext );
24+ if (name .equals (RNQuickSQLiteModule .NAME )) {
25+ return new RNQuickSQLiteModule (reactContext );
2626 } else {
2727 return null ;
2828 }
@@ -33,10 +33,10 @@ public ReactModuleInfoProvider getReactModuleInfoProvider() {
3333 return () -> {
3434 final Map <String , ReactModuleInfo > moduleInfos = new HashMap <>();
3535 moduleInfos .put (
36- RNQuickSQLiteInitModule .NAME ,
36+ RNQuickSQLiteModule .NAME ,
3737 new ReactModuleInfo (
38- RNQuickSQLiteInitModule .NAME ,
39- RNQuickSQLiteInitModule .NAME ,
38+ RNQuickSQLiteModule .NAME ,
39+ RNQuickSQLiteModule .NAME ,
4040 false ,
4141 true ,
4242 true ,
Original file line number Diff line number Diff line change 22
33NS_ASSUME_NONNULL_BEGIN
44
5- @interface RNQuickSQLiteInit : NSObject <NativeRNQuickSQLiteInitSpec >
5+ @interface RNQuickSQLiteModule : NSObject <NativeRNQuickSQLiteModuleSpec >
66
77@property (nonatomic , assign ) BOOL setBridgeOnMainQueue;
88
Original file line number Diff line number Diff line change 77
88using namespace facebook ;
99
10- @implementation RNQuickSQLiteInit
10+ @implementation RNQuickSQLiteModule
1111
1212@synthesize bridge = _bridge;
1313
1414- (std::shared_ptr<facebook::react::TurboModule>)getTurboModule :
1515 (const facebook::react::ObjCTurboModule::InitParams &)params
1616{
17- return std::make_shared<facebook::react::NativeRNQuickSQLiteInitSpecJSI >(params);
17+ return std::make_shared<facebook::react::NativeRNQuickSQLiteModuleSpecJSI >(params);
1818}
1919
2020- (NSNumber *) install {
21- NSLog (@" Installing QuickSQLite module..." );
21+ NSLog (@" Installing RNQuickSQLite module..." );
2222
2323 RCTCxxBridge *cxxBridge = (RCTCxxBridge *)self.bridge ;
2424 if (cxxBridge == nil ) {
Original file line number Diff line number Diff line change @@ -4,4 +4,4 @@ export interface Spec extends TurboModule {
44 install ( ) : boolean
55}
66
7- export default TurboModuleRegistry . getEnforcing < Spec > ( 'RNQuickSQLiteInit ' )
7+ export default TurboModuleRegistry . getEnforcing < Spec > ( 'RNQuickSQLiteModule ' )
Original file line number Diff line number Diff line change 88/* eslint-disable @typescript-eslint/no-explicit-any */
99/* eslint-disable @typescript-eslint/no-unsafe-call */
1010
11- import RNQuickSQLiteInit from './NativeRNQuickSQLiteInit '
11+ import RNQuickSQLiteModule from './NativeRNQuickSQLiteModule '
1212
1313declare global {
1414 function nativeCallSyncHook ( ) : unknown
1515 var __QuickSQLiteProxy : object | undefined
1616}
1717
1818if ( global . __QuickSQLiteProxy == null ) {
19- if ( RNQuickSQLiteInit == null || RNQuickSQLiteInit . install == null ) {
19+ if ( RNQuickSQLiteModule == null || RNQuickSQLiteModule . install == null ) {
2020 throw new Error (
2121 'QuickSQLite TurboModule not found. Maybe try rebuilding the app.'
2222 )
2323 }
2424
2525 // Call the synchronous blocking install() function
26- const result = RNQuickSQLiteInit . install ( )
26+ const result = RNQuickSQLiteModule . install ( )
2727 if ( result !== true ) {
2828 throw new Error (
2929 `Failed to install react-native-quick-sqlite: The QuickSQLite TurboModule could not be installed! Looks like something went wrong when installing JSI bindings: ${ result } `
You can’t perform that action at this time.
0 commit comments