diff --git a/lyrics/20-lyricwiki.rb b/lyrics/20-lyricwiki.rb
index 3e284ff9e532e48552f306e3e0bfdfcc036f9cb1..fde22e44a835144efddc0fd7dfa55fe039a2497c 100755 (executable)
--- a/lyrics/20-lyricwiki.rb
+++ b/lyrics/20-lyricwiki.rb
#!/usr/bin/env ruby
#
-# (c) 2004-2008 The Music Player Daemon Project
+# (c) 2004-2017 The Music Player Daemon Project
# http://www.musicpd.org/
#
# This program is free software; you can redistribute it and/or modify
exit(69) if url =~ /action=edit$/
response = open(URI.parse(url)).read
-if not response =~ /<div class='lyricbox'>\s*(.*?)\s*<!--/im
+if not response =~ /<div class='lyricbox'>\s*(.*?)\s*<div class='lyricsbreak'>/im
$stderr.puts "No <div class='lyricbox'> in lyrics page!\n"
exit(1)
end
-if not $1 =~ /^.*<\/script>(.*?)$/im
- $stderr.puts "Couldn't remove leading XML tags in lyricbox!\n"
- exit(1)
-end
-
lyrics = $1.gsub(/<br \/>/, "\n")
if lyrics.respond_to?(:force_encoding)