implemented Flask-SQLAlchemy
allow flashing