You've already forked tf2wikipricing
lint: remove unnecessary escape in regex
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { $T } from './localization'
|
||||
|
||||
function toFixed(num: number, fixed: number) {
|
||||
const re = new RegExp('^-?\\d+(?:\.\\d{0,' + (fixed || -1) + '})?');
|
||||
const re = new RegExp('^-?\\d+(?:.\\d{0,' + (fixed || -1) + '})?');
|
||||
return num.toString().match(re)[0];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user