Эх сурвалжийг харах

Locales separating decimals with commas

Added regex for locales separating decimals with commas, not periods
Francesco Ferraro 3 жил өмнө
parent
commit
2852449aa9

+ 1 - 1
Extensions/firefox/return-youtube-dislike.script.js

@@ -150,7 +150,7 @@ function numberFormat(numberState) {
     maximumFractionDigits: 1
     maximumFractionDigits: 1
   });
   });
 
 
-  return formatter.format(roundDown(numberState)).replace('.0', '');
+  return formatter.format(roundDown(numberState)).replace(/.0|,0/gi, '');
 }
 }
 
 
 function setEventListeners(evt) {
 function setEventListeners(evt) {