Possible fix for postgres issue on heroku, cleaned up twitter script error checking