feat: update slug2id for deleted post

This commit is contained in:
DIYgod 2023-01-09 13:06:56 +00:00
parent c8f51a20e6
commit 72a53573cb
No known key found for this signature in database
GPG Key ID: D159328F47A80DCA
1 changed files with 1 additions and 1 deletions

View File

@ -67,7 +67,7 @@ export async function getIdBySlug(slug: string, handle: string) {
)
.then((res) => res.json())
.then((note) => {
if (note && getSlug(note) !== slug) {
if ((note && getSlug(note) !== slug) || note.deleted) {
cacheDelete(["slug2id", handle, slug])
}
})