mirror of
https://github.com/chartjs/Chart.js.git
synced 2024-10-07 04:39:06 +02:00
Fix handling of moments by scale.getRightValue
When using {x: moment, y: value} datapoints
This commit is contained in:
parent
529ebedc90
commit
966d737617
@ -396,7 +396,7 @@ module.exports = function(Chart) {
|
||||
}
|
||||
// If it is in fact an object, dive in one more level
|
||||
if (typeof(rawValue) === "object") {
|
||||
if (rawValue instanceof Date) {
|
||||
if ((rawValue instanceof Date) || (rawValue.isValid)) {
|
||||
return rawValue;
|
||||
} else {
|
||||
return getRightValue(this.isHorizontal() ? rawValue.x : rawValue.y);
|
||||
|
Loading…
Reference in New Issue
Block a user