mirror of
https://github.com/fluencelabs/wasmer
synced 2025-03-16 16:20:49 +00:00
Improved wasmer invoke based on feedback
This commit is contained in:
parent
be1f192df2
commit
f3b7c6b321
@ -687,10 +687,7 @@ fn execute_wasm(options: &Run) -> Result<(), String> {
|
||||
args.push(Value::I32(x));
|
||||
}
|
||||
|
||||
let invoke_fn = match options.invoke.as_ref() {
|
||||
Some(fun) => fun,
|
||||
_ => "main",
|
||||
};
|
||||
let invoke_fn = options.invoke.clone().unwrap_or("main".to_owned());
|
||||
instance
|
||||
.dyn_func(&invoke_fn)
|
||||
.map_err(|e| format!("{:?}", e))?
|
||||
|
Loading…
x
Reference in New Issue
Block a user