Fix wrong image folder path

This commit is contained in:
2023-10-09 15:11:07 +02:00
parent 127b2b302f
commit 75feb124ba
2 changed files with 5 additions and 1 deletions

View File

@@ -15,7 +15,9 @@ Common.getImageList = async function (manifestId) {
folderName += '_iiif';
return await fs.promises.readdir(`${process.env.IMAGES_DIR}/${folderName}`);
let baseFolder = folderName.split('_')[0] + '_' + folderName.split('_')[1] + '_iiif';
return await fs.promises.readdir(`${process.env.IMAGES_DIR}/${baseFolder}/${folderName}`);
}
/**
* @param {string} imageId The image's id as a URL to the image server