mirror of
https://github.com/mii443/wasmer.git
synced 2025-12-07 21:28:21 +00:00
Update examples that use RuntimeError::custom to use return a custom
error type directly.
This commit is contained in:
@@ -63,7 +63,7 @@ impl RuntimeError {
|
||||
}
|
||||
|
||||
/// Raises a custom user Error
|
||||
#[deprecated(since = "2.1.1", note = "prefer using RuntimeError::custom instead")]
|
||||
#[deprecated(since = "2.1.1", note = "return a Result from host functions instead")]
|
||||
pub fn raise(error: Box<dyn Error + Send + Sync>) -> ! {
|
||||
let error = Self::custom(error);
|
||||
let js_error: JsValue = error.into();
|
||||
|
||||
Reference in New Issue
Block a user