diff --git a/src/lib.rs b/src/lib.rs index ef0e674..003ac34 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -481,7 +481,7 @@ pub mod get_data { #[derive(Deserialize, Serialize, Debug)] struct WolvesResultUser { committee: String, - wolves_id: String, + member_id: String, first_name: String, last_name: String, contact_email: String, @@ -532,7 +532,7 @@ pub mod get_data { // list of users that need to be updated for this server let mut user_to_update = vec![]; for user in get_wolves_sub(&config, wolves_api).await { - let id = user.wolves_id.parse::().unwrap_or_default(); + let id = user.member_id.parse::().unwrap_or_default(); match existing.get(&(id as i64)) { None => { // user does not exist already, add everything @@ -609,7 +609,7 @@ pub mod get_data { ON CONFLICT(id_wolves) DO UPDATE SET email = $2 ", ) - .bind(&user.wolves_id) + .bind(&user.member_id) .bind(&user.contact_email) .fetch_optional(db) .await @@ -629,7 +629,7 @@ pub mod get_data { ", ) .bind(*server.as_u64() as i64) - .bind(&user.wolves_id) + .bind(&user.member_id) .bind(&user.expiry) .fetch_optional(db) .await