Browse Source

Fix mapToTargetIds #1220

pull/1177/merge
Masayuki Tanaka 10 years ago
parent
commit
da665bc710
  1. 2
      c3.js
  2. 2
      c3.min.js
  3. 2
      src/data.js

2
c3.js

@ -1789,7 +1789,7 @@
};
c3_chart_internal_fn.mapToTargetIds = function (ids) {
var $$ = this;
return ids ? (isString(ids) ? [ids] : ids) : $$.mapToIds($$.data.targets);
return ids ? [].concat(ids) : $$.mapToIds($$.data.targets);
};
c3_chart_internal_fn.hasTarget = function (targets, id) {
var ids = this.mapToIds(targets), i;

2
c3.min.js vendored

File diff suppressed because one or more lines are too long

2
src/data.js

@ -147,7 +147,7 @@ c3_chart_internal_fn.mapToIds = function (targets) {
};
c3_chart_internal_fn.mapToTargetIds = function (ids) {
var $$ = this;
return ids ? (isString(ids) ? [ids] : ids) : $$.mapToIds($$.data.targets);
return ids ? [].concat(ids) : $$.mapToIds($$.data.targets);
};
c3_chart_internal_fn.hasTarget = function (targets, id) {
var ids = this.mapToIds(targets), i;

Loading…
Cancel
Save