mpv-notify icon indicating copy to clipboard operation
mpv-notify copied to clipboard

local scope on mbid variable

Open geolaw opened this issue 5 years ago • 1 comments

I see this is no longer being supported.

I found your script and have been messing around with it on an arch install which has hooks into mpv playback via ranger. I was finding that although the "d" variable on the musicbrainz look up was coming back with valid XML that it was not correctly getting passed back to the coverart look up.
I finally tracked it down to the local scope on mbid with the string.match

local mbid = string.match(d or "", "<%srelease%s+[^>]id%s=%s['"]%s*([0-9a-fA-F-]+)%s*['"]")

Removing the local scope fixed this : mbid = string.match(d or "", "<%srelease%s+[^>]id%s=%s['"]%s*([0-9a-fA-F-]+)%s*['"]")

Based on other issues, I forked it over on gitlab with credit given :) https://gitlab.com/geolaw/mpv-notify

geolaw avatar Jan 29 '19 17:01 geolaw