lehen commita
This commit is contained in:
+2
-2
@@ -101,7 +101,7 @@ pub fn create(
|
||||
Ok(_) => ValidationErrors::new(),
|
||||
Err(e) => e,
|
||||
};
|
||||
if Blog::find_by_fqn(&conn, slug).is_ok() {
|
||||
if Blog::find_by_fqn(&conn, &slug).is_ok() {
|
||||
errors.add(
|
||||
"title",
|
||||
ValidationError {
|
||||
@@ -122,7 +122,7 @@ pub fn create(
|
||||
let blog = Blog::insert(
|
||||
&conn,
|
||||
NewBlog::new_local(
|
||||
slug.into(),
|
||||
slug.clone().into(),
|
||||
form.title.to_string(),
|
||||
String::from(""),
|
||||
Instance::get_local()
|
||||
|
||||
Reference in New Issue
Block a user