This commit is contained in:
Mr Swift
2024-02-28 15:36:25 -08:00
parent 4093f54402
commit 8a3e54d65e
2 changed files with 10 additions and 2 deletions
+7 -2
View File
@@ -10,8 +10,13 @@ const serialChecker = (serial, type = 'guaranteeSerial', g = 1) => {
if (type === 'guaranteeSerial') exelsPath = guaranteeSerialsPath + `/${g}`;
if (type === 'orginality') exelsPath = productSerialsPath + `/${g}`;
const lowerSerial = serial.toLowerCase().replace("-", "").replace("_", "");
const newTxt = serial.toLowerCase().split("-")
let lowerSerial = ""
for(const item of newTxt){
lowerSerial += item
}
try {
const serialFiles = await fs.readdirSync(exelsPath);
if ((serialFiles?.length) <= 0) {
+3
View File
@@ -0,0 +1,3 @@
const txt = "s-01E33301G-M810924394"
console.log(newitem)