Fixed errors preventing heroku deploy