Added a console log to work out why graph isn't working