<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_username(user, apps):
 """When using broser login, username was not stored so look it up"""

    if not user:
        return None

    apps = [a for a in apps if a.instance == user.instance]

    if not apps:
        return None

    from toot.api import verify_credentials
    creds = verify_credentials(apps.pop(), user)

    return User(user.instance, creds['username'], user.access_token)