maybe unpublishing a post works now?

This commit is contained in:
2024-08-19 09:55:01 +02:00
parent bfee85a963
commit cc7bd3a416
2 changed files with 6 additions and 1 deletions

View File

@ -161,7 +161,11 @@ async fn blogpost_unpublished(
config: &State<Config>,
) -> String {
if blogpost.pw == &config.wordpress_key {
Notification::delete_by_link(&db, blogpost.article_url).await;
Notification::delete_by_link(
&db,
&urlencoding::decode(blogpost.article_url).expect("UTF-8"),
)
.await;
"ACK".into()
} else {
"WRONG pw".into()