We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 13bf9cd commit 1da15a6Copy full SHA for 1da15a6
src/categories.rs
@@ -100,7 +100,7 @@ struct NewCategory {
100
101
pub fn sync() -> CargoResult<()> {
102
use diesel::pg::upsert::*;
103
- use diesel::expression::dsl::any;
+ use diesel::expression::dsl::all;
104
105
let conn = db::connect_now().unwrap();
106
@@ -136,7 +136,7 @@ pub fn sync() -> CargoResult<()> {
136
.returning(categories::slug)
137
.get_results::<String>(&conn)?;
138
139
- let to_delete = categories::table.filter(categories::slug.ne(any(slugs)));
+ let to_delete = categories::table.filter(categories::slug.ne(all(slugs)));
140
diesel::delete(to_delete).execute(&conn)?;
141
Ok(())
142
})
0 commit comments