_updateDatasets(mode) {
    if (this.notifyPlugins('beforeDatasetsUpdate', {mode, cancelable: true}) === false) {
      return;
    }

    for (let i = 0, ilen = this.data.datasets.length; i < ilen; ++i) {
      this.getDatasetMeta(i).controller.configure();
    }

    for (let i = 0, ilen = this.data.datasets.length; i < ilen; ++i) {
      this._updateDataset(i, isFunction(mode) ? mode({datasetIndex: i}) : mode);
    }

    this.notifyPlugins('afterDatasetsUpdate', {mode});
  }
Updates all datasets unless a plugin returns `false` to the `beforeDatasetsUpdate`
hook, in which case, plugins will not be called on `afterDatasetsUpdate`.
@private