diff options
Diffstat (limited to '')
-rw-r--r-- | lib/lsg_irc/last_fm_plugin.ex | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/lsg_irc/last_fm_plugin.ex b/lib/lsg_irc/last_fm_plugin.ex index 04f887c..0c6b8a6 100644 --- a/lib/lsg_irc/last_fm_plugin.ex +++ b/lib/lsg_irc/last_fm_plugin.ex @@ -98,8 +98,7 @@ defmodule LSG.IRC.LastFmPlugin do username = case :dets.lookup(state.dets, id_or_user) do [{_, username}] -> username - _ -> - id_or_user + _ -> id_or_user end case now_playing(username) do @@ -108,7 +107,7 @@ defmodule LSG.IRC.LastFmPlugin do {:ok, map} when is_map(map) -> track = fetch_track(username, map) text = format_now_playing(map, track) - user = if account = IRC.Account.get(username) do + user = if account = IRC.Account.get(id_or_user) do user = IRC.UserTrack.find_by_account(message.network, account) if(user, do: user.nick, else: account.name) else |