

def get_user(email_or_id):
    query = User.query
    is_id = (len(str(email_or_id).split('-')) == 5)
    if is_id:
        user = query.get(email_or_id)
    else:
        user = query.filter_by(email=email_or_id).first()
    return user

dataset/ETHPy150Open tooxie/shiva-server/shiva/admin.py get_user/original