Commit 009f2b02 authored by Antoine Cellerier's avatar Antoine Cellerier

Update lua meta script to new API (untested).

parent 8a16cc00
......@@ -40,12 +40,12 @@ function fetch_art()
else
return nil
end
fd = vlc.stream_new( "http://images.google.com/images?q=" .. get_query( title ) )
page = vlc.stream_read( fd, 65653 )
vlc.stream_delete( fd )
fd = vlc:stream( "http://images.google.com/images?q=" .. get_query( title ) )
page = fd:read( 65653 )
fd = nil
_, _, arturl = string.find( page, "imgurl=([^&]+)" )
if arturl then
return vlc.decode_uri(arturl)
return vlc.strings.decode_uri(arturl)
else
return nil
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment