fix: oops

This commit is contained in:
Skye 2023-03-10 20:46:30 +09:00
parent e5d85879b9
commit 3511feec73
Signed by: me
GPG key ID: 0104BC05F41B77B8

View file

@ -58,10 +58,10 @@ client.on("messageCreate", async (message) => {
const context = [ const context = [
...msgs ...msgs
.filter((msg) => { .filter((msg) => {
if (message.webhookId) return false; if (msg.webhookId) return false;
if (message.author.bot && msg.author !== msg.author.client.user) if (msg.author.bot && msg.author !== msg.author.client.user)
return false; return false;
if (message.content.startsWith("\\")) return false; if (msg.content.startsWith("\\")) return false;
return true; return true;
}) })
.mapValues<ChatCompletionRequestMessage>((msg) => { .mapValues<ChatCompletionRequestMessage>((msg) => {