Fix graph generation on Heroku