Various QOL changes

This commit is contained in:
ZXY101
2024-02-11 07:25:41 +02:00
parent b1c4029345
commit 83843ff5dd
11 changed files with 128 additions and 19 deletions

View File

@@ -64,7 +64,7 @@ export async function imageToWebp(source: File) {
}
}
export async function updateLastCard(imageData: string | null | undefined, sentence: string) {
export async function updateLastCard(imageData: string | null | undefined, sentence?: string) {
const {
overwriteImage,
enabled,
@@ -88,7 +88,7 @@ export async function updateLastCard(imageData: string | null | undefined, sente
const fields: Record<string, any> = {};
if (grabSentence) {
if (grabSentence && sentence) {
fields[sentenceField] = sentence;
}