Fix: Use default reaction on bootstrap (#3965)

This commit is contained in:
Tiago Vasconcelos
2026-05-14 04:56:41 +02:00
committed by GitHub
parent 810a13722c
commit c9c68bd8d7
2 changed files with 7 additions and 6 deletions
+1 -1
View File
File diff suppressed because one or more lines are too long
+6 -5
View File
@@ -1,16 +1,17 @@
function eventReaction(amount) {
localUrl = ''
reaction = localStorage.getItem('lnbits.reactions')
if (!reaction || reaction === 'None') {
const reaction =
Quasar.LocalStorage.getItem('lnbits.reactions') || SETTINGS.defaultReaction
if (!reaction || reaction.toLowerCase() === 'none') {
return
}
try {
if (amount < 0) {
return
}
reaction = localStorage.getItem('lnbits.reactions')
if (reaction) {
window[reaction.split('|')[1]]()
if (typeof window[reaction] === 'function') {
window[reaction]()
}
} catch (e) {
console.log(e)