Feat: コマンドを並列処理
This commit is contained in:
@@ -84,7 +84,7 @@ try {
|
|||||||
|
|
||||||
ueuses = [...new Set(ueuses)];
|
ueuses = [...new Set(ueuses)];
|
||||||
|
|
||||||
for (const ueuse of ueuses) {
|
await Promise.all(ueuses.map(async (ueuse) => {
|
||||||
const mem = Memory.memory;
|
const mem = Memory.memory;
|
||||||
let text = ueuse.text;
|
let text = ueuse.text;
|
||||||
text = text.replace(`@${mem.userid}`, "");
|
text = text.replace(`@${mem.userid}`, "");
|
||||||
@@ -103,7 +103,8 @@ try {
|
|||||||
|
|
||||||
if (!response.success)
|
if (!response.success)
|
||||||
console.warn("ユーズの作成に失敗しました:", response.error_code);
|
console.warn("ユーズの作成に失敗しました:", response.error_code);
|
||||||
break;
|
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const args = commandRow.replace("/", "").split(" ");
|
const args = commandRow.replace("/", "").split(" ");
|
||||||
@@ -136,7 +137,7 @@ try {
|
|||||||
console.warn("ユーズの作成に失敗しました:", response.error_code);
|
console.warn("ユーズの作成に失敗しました:", response.error_code);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}));
|
||||||
|
|
||||||
process.exit(0);
|
process.exit(0);
|
||||||
} catch (err: any) {
|
} catch (err: any) {
|
||||||
|
|||||||
Reference in New Issue
Block a user