dimanche 27 mars 2016

Unable to keep default auth.user in field of table between logouts in web2py

In my db.py file I have defined a table called recipe with a field as Field('cook','string',default=auth.user.username) which basically creates a recipe with an uploaded image and username. It works fine but whenever I logout I get an error saying ('NoneType' object has no attribute 'username')

Aucun commentaire:

Enregistrer un commentaire