diff --git a/src/content/docs/es/start/migrate/from-tauri-1.mdx b/src/content/docs/es/start/migrate/from-tauri-1.mdx index 39e714b00d..b495e39c9f 100644 --- a/src/content/docs/es/start/migrate/from-tauri-1.mdx +++ b/src/content/docs/es/start/migrate/from-tauri-1.mdx @@ -488,7 +488,7 @@ use tauri_plugin_global_shortcut::GlobalShortcutExt; tauri::Builder::default() .plugin( - tauri_plugin_global_shortcut::Builder::with_handler(|app, shortcut| { + tauri_plugin_global_shortcut::Builder::new().with_handler(|app, shortcut| { println!("Shortcut triggered: {:?}", shortcut); }) .build(), diff --git a/src/content/docs/start/migrate/from-tauri-1.mdx b/src/content/docs/start/migrate/from-tauri-1.mdx index 72b5c058c8..272a0b9908 100644 --- a/src/content/docs/start/migrate/from-tauri-1.mdx +++ b/src/content/docs/start/migrate/from-tauri-1.mdx @@ -494,7 +494,7 @@ use tauri_plugin_global_shortcut::GlobalShortcutExt; tauri::Builder::default() .plugin( - tauri_plugin_global_shortcut::Builder::with_handler(|app, shortcut| { + tauri_plugin_global_shortcut::Builder::new().with_handler(|app, shortcut| { println!("Shortcut triggered: {:?}", shortcut); }) .build(), diff --git a/src/content/docs/zh-cn/start/migrate/from-tauri-1.mdx b/src/content/docs/zh-cn/start/migrate/from-tauri-1.mdx index b31143abac..f559df20b2 100644 --- a/src/content/docs/zh-cn/start/migrate/from-tauri-1.mdx +++ b/src/content/docs/zh-cn/start/migrate/from-tauri-1.mdx @@ -489,7 +489,7 @@ use tauri_plugin_global_shortcut::GlobalShortcutExt; tauri::Builder::default() .plugin( - tauri_plugin_global_shortcut::Builder::with_handler(|app, shortcut| { + tauri_plugin_global_shortcut::Builder::new().with_handler(|app, shortcut| { println!("Shortcut triggered: {:?}", shortcut); }) .build(),