Skip to content

Commit

Permalink
Use StatusBackendClient in native code and pass message argument
Browse files Browse the repository at this point in the history
  • Loading branch information
ilmotta authored and siddarthkay committed Jan 23, 2025
1 parent 378d5d8 commit 4584c51
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ class StatusModule(private val reactContext: ReactApplicationContext, private va
fun intendedPanic(message: String) {
StatusBackendClient.executeStatusGoRequest(
endpoint = "IntendedPanic",
requestBody = "",
requestBody = message,
statusgoFunction = { Statusgo.intendedPanic(message) },
)
}
Expand Down
6 changes: 5 additions & 1 deletion modules/react-native-status/ios/RCTStatus/RCTStatus.m
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,11 @@ - (void)handleSignal:(NSString *)signal
#if DEBUG
NSLog(@"IntendedPanic() method called");
#endif
StatusgoIntendedPanic(message);
[StatusBackendClient executeStatusGoRequest:@"IntendedPanic"
body:message
statusgoFunction:^NSString *{
return StatusgoIntendedPanic(message);
}];
}

RCT_EXPORT_BLOCKING_SYNCHRONOUS_METHOD(fleets) {
Expand Down

0 comments on commit 4584c51

Please sign in to comment.