misc.generate: split embeds every 3 images
This commit is contained in:
parent
8f016f7361
commit
4df473339d
1 changed files with 3 additions and 1 deletions
|
@ -430,10 +430,12 @@ generate.callback = async function (msg, line) {
|
|||
file: images,
|
||||
};
|
||||
|
||||
let splitIndex = 0;
|
||||
for (const index in images) {
|
||||
if (index % 3 == 0) splitIndex++;
|
||||
out.embeds.push({
|
||||
title,
|
||||
url: "https://www.craiyon.com",
|
||||
url: "https://www.craiyon.com/?" + splitIndex,
|
||||
image: {
|
||||
url: `attachment://${index}.jpg`,
|
||||
},
|
||||
|
|
Loading…
Reference in a new issue