From: Jukka Kurkela Date: Wed, 30 Dec 2020 13:31:44 +0000 (+0200) Subject: Line: Set points on resize (to reset Path2D cache) (#8250) X-Git-Tag: v3.0.0-beta.8~19 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6ffc380c6ac4622585cf1d58b19a19ec4354ae76;p=thirdparty%2FChart.js.git Line: Set points on resize (to reset Path2D cache) (#8250) --- diff --git a/src/controllers/controller.line.js b/src/controllers/controller.line.js index e536f5d49..16edd7cb3 100644 --- a/src/controllers/controller.line.js +++ b/src/controllers/controller.line.js @@ -28,14 +28,10 @@ export default class LineController extends DatasetController { } // Update Line - // In resize mode only point locations change, so no need to set the points or options. + line.points = points; + // In resize mode only point locations change, so no need to set the options. if (mode !== 'resize') { - const properties = { - points, - options: me.resolveDatasetElementOptions() - }; - - me.updateElement(line, undefined, properties, mode); + me.updateElement(line, undefined, {options: me.resolveDatasetElementOptions()}, mode); } // Update Points