Fix notification expire timeout being treated as seconds instead of milliseconds

This commit is contained in:
David Heinemeier Hansson committed 2026-06-29 13:24:04 -05:00
1 parent 1220a031b3
commit fed2fd8e3d
2 files changed
+6 -4

No files matched your search

+5 -3
View File
@@ -109,9 +109,11 @@ Item {
}
function requestedDuration(expireTimeout) {
var seconds = Number(expireTimeout || 0)
if (!isFinite(seconds) || seconds <= 0) return 0
return Math.round(seconds * 1000)
// FreeDesktop notification spec (and Quickshell) report expireTimeout in
// milliseconds, so pass it through directly.
var ms = Number(expireTimeout || 0)
if (!isFinite(ms) || ms <= 0) return 0
return Math.round(ms)
}
// DND bypass: only let through notifications we trust to be intentional