Explorar o código

Remove end parenthesis from weight

missionfloyd hai 1 ano
pai
achega
56ef5e9d48
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      javascript/edit-attention.js

+ 1 - 1
javascript/edit-attention.js

@@ -86,7 +86,7 @@ function keyupEditAttention(event) {
     }
     }
 
 
     var end = text.slice(selectionEnd + 1).indexOf(closeCharacter) + 1;
     var end = text.slice(selectionEnd + 1).indexOf(closeCharacter) + 1;
-    var weight = parseFloat(text.slice(selectionEnd + 1, selectionEnd + 1 + end));
+    var weight = parseFloat(text.slice(selectionEnd + 1, selectionEnd + end));
     if (isNaN(weight)) return;
     if (isNaN(weight)) return;
 
 
     weight += isPlus ? delta : -delta;
     weight += isPlus ? delta : -delta;