chore: use expect instead of unwrap

pull/11/head
paring 2022-11-02 21:10:11 +09:00
parent 6376ecf4ac
commit a9673837a0
Signed by: pikokr
GPG Key ID: 2C097B03E9D823C4
1 changed files with 1 additions and 1 deletions

View File

@ -123,7 +123,7 @@ pub fn stop() -> Result<(), Error> {
// This is executed in another thread!
extern "system" fn hook_callback(code: i32, wparam: usize, lparam: isize) -> isize {
let processed_hook_id: HHOOK = unsafe { HOOK_ID.unwrap() };
let processed_hook_id: HHOOK = unsafe { HOOK_ID.expect("HOOK_ID is None") };
if code < 0 {
// Don't do anything, just return