math: clean definition and set array index base to ZERO

This commit is contained in:
jean-emmanuel 2017-01-24 20:49:04 +01:00
parent 85aa663c63
commit 0381e0aade

View file

@ -1,5 +1,3 @@
var math = require('mathjs')
module.exports = {
clip: function(value,range) {
@ -72,5 +70,10 @@ module.exports = {
return hsb
},
math: math
math: function(){
var math = require('mathjs')
// set math's parser array index base to zero
math.expression.transform = Object.create(math)
return math
}()
}