Major refactor of song upload code.