fix(est-test): reject duplicate JDL tables
This commit is contained in:
@@ -297,7 +297,12 @@ function output(project) {
|
||||
return { bytes: pack(files), warnings };
|
||||
}
|
||||
function read(bytes, project) {
|
||||
const files = new Map([...unpack(bytes)].map(([k, v]) => [k.toLowerCase(), v]));
|
||||
const files = new Map();
|
||||
for (const [name, data] of unpack(bytes)) {
|
||||
const key = name.toLowerCase();
|
||||
if (files.has(key)) throw Error(`JDL 파일명 중복: ${name}`);
|
||||
files.set(key, data);
|
||||
}
|
||||
if (!files.has("global.ini") || !files.has("main.txt"))
|
||||
throw Error("Global.ini/Main.txt 없는 JDL입니다.");
|
||||
const main = decoder
|
||||
|
||||
Reference in New Issue
Block a user