Skip to content

Commit cf9f6aa

Browse files
authored
fix(core): fix typo in notifications, closes #2330 (#2331)
* fix(core): fix typo in notifications, closes #2330 * Update core-notification-typo.md * [skip ci]
1 parent 4678144 commit cf9f6aa

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changes/core-notification-typo.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tauri": patch
3+
---
4+
5+
Fix `Notification.requestPermission()` throwing `Unhandled Promise Rejection: TypeError: undefined is not a function (near '...window.__TAURI__.invoke...')`

core/tauri/scripts/core.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ if (!String.prototype.startsWith) {
260260

261261
function requestPermission() {
262262
return window.__TAURI__
263-
.invoke(
263+
._invoke(
264264
'tauri',
265265
{
266266
__tauriModule: 'Notification',

0 commit comments

Comments
 (0)