From d3c1ee700d368d0944c57a8b27cbc8c0fa6e0c3b Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Thu, 18 Feb 2021 19:13:19 +0100 Subject: [PATCH] Inverted first and last name when creating account --- src/helpers/account_helper.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/helpers/account_helper.rs b/src/helpers/account_helper.rs index 7a06098..477f7f5 100644 --- a/src/helpers/account_helper.rs +++ b/src/helpers/account_helper.rs @@ -28,8 +28,8 @@ use crate::utils::user_data_utils::user_data_path; /// Create a new account pub fn create(new_account: &NewAccount) -> ResultBoxError { database::InsertQuery::new(USERS_TABLE) - .add_str("nom", &new_account.first_name) - .add_str("prenom", &new_account.last_name) + .add_str("prenom", &new_account.first_name) + .add_str("nom", &new_account.last_name) .add_str("date_creation", &mysql_date()) .add_str("mail", &new_account.email) .add_str("password", &hash_password(&new_account.password)?)