Skip to content
This repository has been archived by the owner on Jul 29, 2019. It is now read-only.

Commit

Permalink
Small fix on ref usage in DataGroup (#3198)
Browse files Browse the repository at this point in the history
  • Loading branch information
wimrijnders authored and yotamberk committed Jun 22, 2017
1 parent 2eb4bbc commit d8458a9
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/graph3d/DataGroup.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ function DataGroup() {
* @param {Number} style Style Number
*/
DataGroup.prototype.initializeData = function(graph3d, rawData, style) {
var me = this;

// unsubscribe from the dataTable
if (this.dataSet) {
this.dataSet.off('*', this._onChange);
Expand Down Expand Up @@ -65,8 +63,9 @@ DataGroup.prototype.initializeData = function(graph3d, rawData, style) {
this.dataTable = data;

// subscribe to changes in the dataset
var me = this;
this._onChange = function () {
me.setData(me.dataSet);
graph3d.setData(me.dataSet);
};
this.dataSet.on('*', this._onChange);

Expand Down

0 comments on commit d8458a9

Please sign in to comment.