From b5e1348d09901474d3172b677a1b7a7c4535f22b Mon Sep 17 00:00:00 2001 From: "Min S. Kim" Date: Sat, 11 Jan 2025 16:41:41 -0800 Subject: [PATCH] Remove obsolete reset_admin_password function --- CHANGELOG.md | 5 +++++ src/graphql/account.rs | 11 ----------- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0273020..aca13aa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -45,6 +45,11 @@ Versioning](https://semver.org/spec/v2.0.0.html). - The GraphQL API for `WindowsThreat` event structure is changed to return `ID` type instead of `usize` type value for the `cluster_id` field. +### Removed + +- Removed `graphql::account::reset_admin_password` function as it was obsoleted + by the GraphQL API `resetAdminPassword`. + ### Fixed - Resolved an issue in the `applyNode` GraphQL API, where configuration values diff --git a/src/graphql/account.rs b/src/graphql/account.rs index 3f31295..a99a495 100644 --- a/src/graphql/account.rs +++ b/src/graphql/account.rs @@ -803,17 +803,6 @@ pub fn set_initial_admin_password(store: &Store) -> anyhow::Result<()> { map.insert(&account) } -/// Resets the administrator password to the initial value. -/// -/// # Errors -/// -/// This function returns an error if it fails to generate random bytes for password. -pub fn reset_admin_password(store: &Store) -> anyhow::Result<()> { - let map = store.account_map(); - let account = initial_credential()?; - map.put(&account) -} - /// Returns the initial administrator username and salted password. /// /// # Errors