Fixes a javascript error in the graph widget.