Compare commits

..

No commits in common. "c41dc0853af570018c3034c73076e97935b91f3b" and "bfee85a9635ccf3d41f21c250ba4537936971034" have entirely different histories.

2 changed files with 1 additions and 6 deletions

View File

@ -181,7 +181,6 @@ ORDER BY read_at DESC, created_at DESC;
} }
pub(crate) async fn delete_by_link(db: &sqlx::Pool<Sqlite>, link: &str) { pub(crate) async fn delete_by_link(db: &sqlx::Pool<Sqlite>, link: &str) {
let link = Some(link);
sqlx::query!("DELETE FROM notification WHERE link=?", link) sqlx::query!("DELETE FROM notification WHERE link=?", link)
.execute(db) .execute(db)
.await .await

View File

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