# api/core/auth.py

from flask import g
from ..models import User

@auth.verify_password
def verify_password(username, password):
    user = User.by_email(username, password)
    if not user or not user.verify_password(password):
        return False
    g.user = user
    return True

42f3523a3159b63627740f2454f66bc34506ca65
<mask token>

<mask token>


@auth.verify_password
def verify_password(username, password):
    user = User.by_email(username, password)
    if not user or not user.verify_password(password):
        return False
    g.user = user
    return True

from flask import g
from ..models import User


@auth.verify_password
def verify_password(username, password):
    user = User.by_email(username, password)
    if not user or not user.verify_password(password):
        return False
    g.user = user
    return True

# api/core/auth.py

from flask import g
from ..models import User

@auth.verify_password
def verify_password(username, password):
    user = User.by_email(username, password)
    if not user or not user.verify_password(password):
        return False
    g.user = user
    return True
