diff --git a/rust/agama-lib/src/store.rs b/rust/agama-lib/src/store.rs index ecdef07ee..82f7e812c 100644 --- a/rust/agama-lib/src/store.rs +++ b/rust/agama-lib/src/store.rs @@ -51,7 +51,7 @@ impl<'a> Store<'a> { ) -> Result, ServiceError> { Ok(Self { localization: LocalizationStore::new(http_client.clone())?, - users: UsersStore::new()?, + users: UsersStore::new(http_client.clone())?, network: NetworkStore::new(http_client.clone()).await?, product: ProductStore::new(connection.clone()).await?, software: SoftwareStore::new(connection.clone()).await?, diff --git a/rust/agama-lib/src/users/store.rs b/rust/agama-lib/src/users/store.rs index 54087f493..30ef38e4e 100644 --- a/rust/agama-lib/src/users/store.rs +++ b/rust/agama-lib/src/users/store.rs @@ -19,6 +19,7 @@ // find current contact information at www.suse.com. use super::{FirstUser, FirstUserSettings, RootUserSettings, UserSettings, UsersHTTPClient}; +use crate::base_http_client::BaseHTTPClient; use crate::error::ServiceError; /// Loads and stores the users settings from/to the D-Bus service. @@ -27,9 +28,9 @@ pub struct UsersStore { } impl UsersStore { - pub fn new() -> Result { + pub fn new(client: BaseHTTPClient) -> Result { Ok(Self { - users_client: UsersHTTPClient::new()?, + users_client: UsersHTTPClient::new_with_base(client)?, }) }