In /signup route in views.py (used almost everywhere that requires age) and in the get_age() function in app.py (used in profile.html), age is calculated as datetime.year-birthday.year. This only takes into account the years and not the days/months, so that means if someone hasn't had their birthday that year, it will still say their age like they have. In essence, everyone has a birthday of January first when calculating age with this model. To fix this, subtract datetime-birthday and then take only the years portion of the difference or something along those lines.
In /signup route in views.py (used almost everywhere that requires age) and in the get_age() function in app.py (used in profile.html), age is calculated as datetime.year-birthday.year. This only takes into account the years and not the days/months, so that means if someone hasn't had their birthday that year, it will still say their age like they have. In essence, everyone has a birthday of January first when calculating age with this model. To fix this, subtract datetime-birthday and then take only the years portion of the difference or something along those lines.