Skip to content

Commit

Permalink
Fix broken favorite button (only works for songs, not yet for radios …
Browse files Browse the repository at this point in the history
…and podcasts).

Partial fix for #10.
  • Loading branch information
metoule committed Feb 6, 2022
1 parent 2a2e54a commit fab4a1a
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions scripts/deezer/player_observer.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,13 +161,7 @@ function deezerControlMethod_next()
function deezerControlMethod_like()
{
"use strict";
var songId = dzPlayer.getCurrentSong('SNG_ID'),
data = { type: 'song', id: songId };

if (userData.isFavorite('song', songId))
favorite.remove(data);
else
favorite.add(data);
$('.track-actions button.svg-icon-group-btn.option-btn').click();
}

function deezerControlMethod_linkCurrentSong()
Expand Down

0 comments on commit fab4a1a

Please sign in to comment.