mirror of
https://github.com/chartjs/Chart.js.git
synced 2024-10-07 04:39:06 +02:00
Merge pull request #2588 from AllenJB/patch-1
Fix handling of moments by scale.getRightValue
This commit is contained in:
commit
725ee1cc31
@ -396,7 +396,7 @@ module.exports = function(Chart) {
|
|||||||
}
|
}
|
||||||
// If it is in fact an object, dive in one more level
|
// If it is in fact an object, dive in one more level
|
||||||
if (typeof(rawValue) === "object") {
|
if (typeof(rawValue) === "object") {
|
||||||
if (rawValue instanceof Date) {
|
if ((rawValue instanceof Date) || (rawValue.isValid)) {
|
||||||
return rawValue;
|
return rawValue;
|
||||||
} else {
|
} else {
|
||||||
return getRightValue(this.isHorizontal() ? rawValue.x : rawValue.y);
|
return getRightValue(this.isHorizontal() ? rawValue.x : rawValue.y);
|
||||||
|
Loading…
Reference in New Issue
Block a user