removed annoying div thingy
now it doesn't say "<div> something" when the song isn't available on azl
This commit is contained in:
parent
28b6263ac3
commit
b60e351faa
6
main.py
6
main.py
|
@ -1,3 +1,4 @@
|
||||||
|
#!/bin/env python
|
||||||
import azl
|
import azl
|
||||||
import letras
|
import letras
|
||||||
|
|
||||||
|
@ -12,16 +13,21 @@ while True:
|
||||||
song_url = azl.getLink(artist, title)
|
song_url = azl.getLink(artist, title)
|
||||||
un_lyr = azl.getLyrics(song_url)
|
un_lyr = azl.getLyrics(song_url)
|
||||||
fin = azl.parsero(un_lyr)
|
fin = azl.parsero(un_lyr)
|
||||||
|
if fin == '<div id="RTK_u0kw"> <div id="RTK_YamI"> <div id="RTK_9uCq">':
|
||||||
|
fin = "Sorry I couldn't find that song :("
|
||||||
|
print('\n<------------------------------------------------------------->')
|
||||||
print(fin)
|
print(fin)
|
||||||
elif web == 'l':
|
elif web == 'l':
|
||||||
song_url = letras.getLink(artist, title)
|
song_url = letras.getLink(artist, title)
|
||||||
un_lyr = letras.getLyrics(song_url)
|
un_lyr = letras.getLyrics(song_url)
|
||||||
fin = letras.parsero(un_lyr)
|
fin = letras.parsero(un_lyr)
|
||||||
|
print('\n<------------------------------------------------------------->')
|
||||||
print(fin)
|
print(fin)
|
||||||
else:
|
else:
|
||||||
print("I didn't give u that option dude")
|
print("I didn't give u that option dude")
|
||||||
continue
|
continue
|
||||||
while True:
|
while True:
|
||||||
|
print('<------------------------------------------------------------->')
|
||||||
res = input("What's the move? (s to search for another song/q to quit): ")
|
res = input("What's the move? (s to search for another song/q to quit): ")
|
||||||
if res == 's' or res == 'q':
|
if res == 's' or res == 'q':
|
||||||
val = res
|
val = res
|
||||||
|
|
Loading…
Reference in New Issue