def get_music_collection():
    session_music_collection = session.get('session_music_collection')
    if session_music_collection:
        return session_music_collection
    else:
        user_info = model.get_Rdio_info('fake user')
        #call my_rdio_search on current user to return music collection and playlists
        music_collection = my_rdio_search.get_user_collection(user_info)
        session['session_music_collection'] = music_collection
        return music_collection
def get_playlists():
    session_playlists = session.get('session_playlists')
    if session_playlists:
        return session_playlists
    else:
        user_info = model.get_Rdio_info('fake user')
        #call my_rdio_search on current user to return music collection and playlists
        playlists = my_rdio_search.get_user_playlists(user_info)
        session['session_playlists'] = playlists
        return playlists
Example #3
0
def get_playlists():
    session_playlists = session.get('session_playlists')
    if session_playlists:
        return session_playlists
    else:
        user_info = model.get_Rdio_info('fake user')
        #call my_rdio_search on current user to return music collection and playlists
        playlists = my_rdio_search.get_user_playlists(user_info)
        session['session_playlists'] = playlists
        return playlists
Example #4
0
def get_music_collection():
    session_music_collection = session.get('session_music_collection')
    if session_music_collection:
        return session_music_collection
    else:
        user_info = model.get_Rdio_info('fake user')
        #call my_rdio_search on current user to return music collection and playlists
        music_collection = my_rdio_search.get_user_collection(user_info)
        session['session_music_collection'] = music_collection
        return music_collection
def get_token():
    # domain = "space-james.herokuapp.com"
    domain = "localhost"
    user_info = model.get_Rdio_info('fake user')
    token = my_rdio_search.get_user_playback_token(user_info, domain)
    return token
Example #6
0
def get_token():
    # domain = "space-james.herokuapp.com"
    domain = "localhost"
    user_info = model.get_Rdio_info('fake user')
    token = my_rdio_search.get_user_playback_token(user_info, domain)
    return token