Discord timeout 0 clear activity directly

This commit is contained in:
Constantin Piber
2021-08-18 21:39:40 +02:00
parent 3901457218
commit 36bc9c62b0

View File

@ -38,6 +38,12 @@ module.exports = (win, {activityTimoutEnabled, activityTimoutTime}) => {
// stop the clear activity timout
clearTimeout(clearActivity);
// clear directly if timeout is 0
if (songInfo.isPaused && activityTimoutEnabled && activityTimoutTime === 0) {
rpc.clearActivity().catch(console.error);
return;
}
if (songInfo.isPaused) {
// Add an idle icon to show that the song is paused
activityInfo.smallImageKey = "idle";