fixed errors in the model
first run of database migrations
added env again