mirror of
https://github.com/sern-handler/frontpage-bot
synced 2026-06-06 01:16:54 +00:00
fix: actually unverify when editing
This commit is contained in:
@@ -76,7 +76,7 @@ export default function BotForm(props: Props) {
|
||||
<AlertTitle>Warning</AlertTitle>
|
||||
<AlertDescription className="whitespace-pre-line">
|
||||
When resubmitting, the bot will be unverified until the devteam verifies it again.{'\n'}
|
||||
This doesn't apply when it's just regenerating the profile picture
|
||||
This doesn't apply when regenerating the profile picture
|
||||
</AlertDescription>
|
||||
</Alert>
|
||||
</div>
|
||||
|
||||
@@ -28,7 +28,10 @@ export async function submitBotData(prev: any, formData: FormData): Promise<Defa
|
||||
where: {
|
||||
id: parsedData.data.id,
|
||||
},
|
||||
data: parsedData.data,
|
||||
data: {
|
||||
verified: false,
|
||||
...parsedData.data,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const { name, botId, inviteLink, srcLink, description } = parsedData.data;
|
||||
@@ -74,7 +77,6 @@ export async function handleBotVerificationSwitch(data: { id: string, verified:
|
||||
error: `From ${parsedData.error.errors[0].path[0]}: ${parsedData.error.errors[0].message}`,
|
||||
};
|
||||
}
|
||||
console.log(parsedData.data.id, parsedData.data.verified)
|
||||
|
||||
const botUpdate = await prisma.bot.update({
|
||||
where: {
|
||||
|
||||
Reference in New Issue
Block a user