I got an error like
Reduce of empty array with no initial value
when do following:
var fields = $(".invoiceli");
$(document).delegate(fields, 'change', function() {
Array.prototype.reduce.call(fields, function(prev, curr)
//.....
});
})
Can someone point me in the right direction?
Thanks!