Hi, I would like to know if there is a way to increase the rarity precision from 0 to 1000 instead of 0 - 100.
could this work ?
const getRarityWeight = (_path) => {
// check if there is an extension, if not, consider it a directory
const exp = /#(\d+(?:.\d{1,2})?)/;
const weight = exp.exec(_path);
const weightNumber = weight ? parseFloat(weight[1]).toFixed(3) : null;
if (!weightNumber || isNaN(weightNumber)) {
return "required";
}
return weightNumber;
};
Hi, I would like to know if there is a way to increase the rarity precision from 0 to 1000 instead of 0 - 100.
could this work ?
const getRarityWeight = (_path) => {
// check if there is an extension, if not, consider it a directory
const exp = /#(\d+(?:.\d{1,2})?)/;
const weight = exp.exec(_path);
const weightNumber = weight ? parseFloat(weight[1]).toFixed(3) : null;
if (!weightNumber || isNaN(weightNumber)) {
return "required";
}
return weightNumber;
};