Made the model User.by_name() case insensitive
This commit is contained in:
parent
eaa32d9c3a
commit
ddd6883172
@ -108,7 +108,7 @@ class User(Base):
|
||||
|
||||
@classmethod
|
||||
def by_name(cls, name):
|
||||
return DBSession.query(cls).filter(cls.name == name).first()
|
||||
return DBSession.query(cls).filter(cls.name.ilike(name)).first()
|
||||
|
||||
@classmethod
|
||||
def by_id(cls, id):
|
||||
|
Loading…
Reference in New Issue
Block a user