Skip to content

Commit

Permalink
Catch UnsatisfiedLinkError (software-mansion#2128)
Browse files Browse the repository at this point in the history
## Description

Fixes
software-mansion#2115

The `System.loadLibrary("rnscreens")` can throw an exception that
inherits from the `Error` class instead of the `Exception` class.
  • Loading branch information
piaskowyk authored and ja1ns committed Oct 9, 2024
1 parent 5748588 commit fc27e89
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class ScreensModule(private val reactContext: ReactApplicationContext)
} else {
Log.e("[RNScreens]", "Could not install JSI bindings.")
}
} catch (exception: Exception) {
} catch (exception: UnsatisfiedLinkError) {
Log.w("[RNScreens]", "Could not load RNScreens module.")
}
}
Expand Down

0 comments on commit fc27e89

Please sign in to comment.