Optimisations
This commit is contained in:
parent
6085da0329
commit
544568c215
2 changed files with 14 additions and 12 deletions
|
@ -817,6 +817,19 @@ const app = new Vue({
|
|||
}
|
||||
})
|
||||
|
||||
/**
|
||||
* DiscordRPC Reload Return Event
|
||||
* @author @coredev-uk
|
||||
*/
|
||||
ipcRenderer.on('rpcReloaded', (e, user) => {
|
||||
if (user.username) {
|
||||
app.notyf.success(app.stringTemplateParser(app.getLz("settings.option.connectivity.discordRPC.reconnectedToUser"), {
|
||||
user: `${user.username}#${user.discriminator}`,
|
||||
userid: user.id
|
||||
}));
|
||||
}
|
||||
})
|
||||
|
||||
ipcRenderer.on('SoundCheckTag', (event, tag) => {
|
||||
// let replaygain = self.parseSCTagToRG(tag)
|
||||
try {
|
||||
|
|
|
@ -1466,18 +1466,7 @@
|
|||
ipcRenderer.send('cc-logout')
|
||||
},
|
||||
reloadDiscordRPC() {
|
||||
ipcRenderer.invoke('reloadRPC').catch((err) => {
|
||||
console.error(err)
|
||||
})
|
||||
|
||||
ipcRenderer.on('rpcReloaded', (e, user) => {
|
||||
if (user.username) {
|
||||
app.notyf.success(app.stringTemplateParser(app.getLz("settings.option.connectivity.discordRPC.reconnectedToUser"), {
|
||||
user: `${user.username}#${user.discriminator}`,
|
||||
userid: user.id
|
||||
}));
|
||||
}
|
||||
})
|
||||
ipcRenderer.send('reloadRPC')
|
||||
}
|
||||
}
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue