Commit 23d007bb authored by Ryan Herbert's avatar Ryan Herbert

generic_axis.js code quality: duplicate var definition

the variable pos was defined twice and raised a JSHint error.
parent dd1c1857
......@@ -90,16 +90,17 @@ GenericAxis.prototype = {
for (var i=0; i < values.length; i++) {
var value = values[i];
var convert = this.applyConverter(value);
var pos;
if (labels.indexOf(convert) != -1) {
if (typeof label_mapping[convert] === 'undefined') {
var pos = labels.indexOf(convert)/labels.length;
pos = labels.indexOf(convert)/labels.length;
if (this.reverse)
pas = 1 - pos;
this.addLabel("line", convert, pos, convert);
}
} else {
if (this.can_undefined) {
var pos = 1;
pos = 1;
if (this.reverse)
pos = 0;
this.addLabel("line", "?", pos, "?");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment