Skip to content

Commit

Permalink
Update index.js
Browse files Browse the repository at this point in the history
  • Loading branch information
PedroAntunesCosta committed Sep 20, 2024
1 parent 9aa971c commit 162ac5b
Showing 1 changed file with 16 additions and 4 deletions.
20 changes: 16 additions & 4 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -769,10 +769,22 @@ ${textPT}
const subFolder = fileSubFolder ? path.join(baseFolder, fileSubFolder).replace(": ", " - ") : null;
const subcategoryFolder = fileSubcategoryFolder ? path.join(subFolder, fileSubcategoryFolder).replace(": ", " - ") : null;
const filePath = fileSubcategoryFolder ? path.join(subcategoryFolder, fileNameEN).replace(": ", " - ") : fileSubFolder ? path.join(subFolder, fileNameEN).replace(": ", " - ") : path.join(baseFolder, fileNameEN).replace(": ", " - ");
console.log('subFolder:---',subFolder.endsWith(' '), '-----')
console.log('subcategoryFolder:---',subcategoryFolder.endsWith(' '), '-----')
console.log('filePath:---',filePath.endsWith(' '), '-----')

if (subFolder){
if (subFolder.endsWith(' ')) {
console.log(subFolder)
}
}
if (subcategoryFolder){
if (subcategoryFolder.endsWith(' ')) {
console.log(subcategoryFolder)
}
}
if (filePath){
if (filePath.endsWith(' ')) {
console.log(filePath)
}
}

// Array of folders to create
const foldersToCreate = [localeFolder, baseFolder, subFolder, subcategoryFolder].filter(Boolean);

Expand Down

0 comments on commit 162ac5b

Please sign in to comment.