Closed Nixeld closed 1 year ago
Is there any example?
It seams like there's no .
in the webhook content, so .match(/^[^.]+\.?/)?.[0]
might not work?
Here is an example of signing into 5 accounts. There are alot of unnecessary text for accounts which have not have an account on a particular game. If I do anymore accounts than that, I will not receive anything from the webhook due to the 2000 character limit.
This is NOT an unnecessary text .
It means that your account data is not present in the Hoyolab database, which indicates that the account has not engaged in that particular game.
Instead of hiding this message, you should set the parameters in the configuration file to false
.
As your example, it shoud be like:
const profiles = [
{ token: "ltoken=gBxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxCY; ltuid=26XXXXX20;",
genshin: true,
honkai_star_rail: true,
honkai_3: true,
accountName: "account A" },
{ token: "ltoken=gBxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxCY; ltuid=26XXXXX21;",
genshin: true,
honkai_star_rail: false,
honkai_3: false,
accountName: "account B" },
{ token: "ltoken=gBxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxCY; ltuid=26XXXXX22;",
genshin: true,
honkai_star_rail: true,
honkai_3: false,
accountName: "account C" },
{ token: "ltoken=gBxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxCY; ltuid=26XXXXX23;",
genshin: true,
honkai_star_rail: false,
honkai_3: false,
accountName: "account D" },
{ token: "ltoken=gBxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxCY; ltuid=26XXXXX24;",
genshin: true,
honkai_star_rail: true,
honkai_3: false,
accountName: "account E" }
];
Discord webhooks have a 2000 character limit. If the 2000 character limit is exceeded, the webhook will fail to post.
This change shortens the checkInResult by only taking the first sentence.
Before this change, my webhook content is over 2000 characters as I am checking in on 7 different accounts. Only making this change for english as the chinese did not have as many characters.