Update src/ol/spline.js to fix NaN bug in first and last segments