db_actions.py
def update_users_followers(username, follower_id, table, remove=False):
    '''
    Find all the users that %username% follows and 
    update their "followers" list and "followers_count" amount
    '''

    item = table.get_item(Key={'username': username}).get('Item', False)
    item['followers'].remove(follower_id) if remove else item['followers'].append(follower_id)
    table.update_item(
        Key={
            'username': username
        },
        UpdateExpression='SET followers = :val1',
        ExpressionAttributeValues={
            ':val1': item['followers'],
        },
    )

    Find all the users that %username% follows and 
    update their "followers" list and "followers_count" amount
    
Find all the users that %username% follows and
update their "followers" list and "followers_count" amount
Find all the users that %username% follows and update their " followers " list and " followers_count " amount
def update_users_followers(username, follower_id, table, remove=False):
    item = table.get_item(Key={'username': username}).get('Item', False)
    item['followers'].remove(follower_id) if remove else item['followers'].append(follower_id)
    table.update_item(
        Key={
            'username': username
        },
        UpdateExpression='SET followers = :val1',
        ExpressionAttributeValues={
            ':val1': item['followers'],
        },
    )
def update_users_followers ( username , follower_id , table , remove = False ) : item = table . get_item ( Key = { 'username' : username } ) . get ( 'Item' , False ) item [ 'followers' ] . remove ( follower_id ) if remove else item [ 'followers' ] . append ( follower_id ) table . update_item ( Key = { 'username' : username } , UpdateExpression = 'SET followers = :val1' , ExpressionAttributeValues = { ':val1' : item [ 'followers' ] , } , )
Find all the users that %username% follows and
update their "followers" list and "followers_count" amount
Find all the users that %username% follows and update their " followers " list and " followers_count " amount
'''
    Find all the users that %username% follows and 
    update their "followers" list and "followers_count" amount
    '''
username
follower_id
table
remove