Made the model User.by_name() case insensitive
This commit is contained in:
1 parent
eaa32d9c3a
commit
ddd6883172
1 file changed
+1
-1
@@ -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):
|
||||
|
||||
Reference in new issue
Block a user