fix: edit cookie dialog not resetting when create is closed

This commit is contained in:
Andrew Bastin
2023-11-07 13:56:57 +05:30
parent 8387e67fd6
commit 9e43f26563

View File

@@ -147,7 +147,12 @@ const pasteIcon = refAutoReset<typeof IconClipboard | typeof IconCheck>(
watch(
() => props.entry,
() => {
if (props.entry?.type !== "edit") return
if (!props.entry) return
if (props.entry.type === "create") {
rawCookieString.value = ""
return
}
rawCookieString.value = props.entry.currentCookieEntry
}