mirror of
https://github.com/krateng/maloja.git
synced 2023-08-10 21:12:55 +03:00
Added basic scrobbling function
This commit is contained in:
12
cleanup.py
12
cleanup.py
@@ -1,9 +1,21 @@
|
||||
import re
|
||||
|
||||
def fullclean(artist,title):
|
||||
artists = cleanup(removespecial(artist))
|
||||
title = cleantitle(removespecial(title))
|
||||
(title,moreartists) = findartistsintitle(title)
|
||||
artists += moreartists
|
||||
|
||||
return (artists,title)
|
||||
|
||||
def removespecial(s):
|
||||
return s.replace("\t","").replace("␟","").replace("\n","")
|
||||
|
||||
def cleanup(artiststr):
|
||||
|
||||
if artiststr == "":
|
||||
return []
|
||||
|
||||
|
||||
artists = [artiststr]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user