Jun-20-2024, 04:56 PM
(Jun-19-2024, 10:59 PM)deanhystad Wrote:Quote:how do i do a re.IGNORECASE as if you type it in capitals it doesnt catch itWhat do you mean? Is this real re or wtf.regexp? For re, read this:
https://docs.python.org/3/library/re.html
it for my wtf form
if form.un.data: if any (name in field.data for name in form.un.data.split(".", flags=re.I)): raise ValidationError('New password cant contain firstname or lastname')basically if you type in your username in the new password it errors saying cant contain firstname or lastname but if they capitalise it, it lets them have that as a new password, i want to stop that