Skip to content

Commit

Permalink
fix rust warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
fasterthanlime committed May 20, 2020
1 parent c4ed621 commit e21c668
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions napi/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,7 @@ where
call: fn(&F, &JsEnv, Arc<RwLock<O>>, Vec<RawValue>) -> Result<T, JsError>,
}

unsafe extern "C" fn call_method<'a, O, T, F>(env: napi_env, info: napi_callback_info) -> RawValue
unsafe extern "C" fn call_method<O, T, F>(env: napi_env, info: napi_callback_info) -> RawValue
where
T: ToNapi,
{
Expand All @@ -776,8 +776,7 @@ where
let ctx = Box::from_raw(ctx);
let ret = (ctx.call)(&ctx.f, &env, info.this, info.args)?;
Box::leak(ctx);
let ret = ret.to_napi(&env);
ret
ret.to_napi(&env)
})
}

Expand Down

0 comments on commit e21c668

Please sign in to comment.