def filename_for_track(track):
    """
    :return: A safe filename for the given track
    """
    artist = track.user['permalink']
    title = track.title

    return '{}-{}.mp3'.format(artist, title).lower().replace(' ', '_').replace('/', '_')
def filename_for_track ( track ) : artist = track . user [ 'permalink' ] title = track . title return '{}-{}.mp3' . format ( artist , title ) . lower ( ) . replace ( ' ' , '_' ) . replace ( '/' , '_' )
:return: A safe filename for the given track