fix bug in models.py