From fcdfeea54824c849a07b5826e8d234b5e7b37b1c Mon Sep 17 00:00:00 2001 From: sigoden Date: Tue, 11 Jun 2024 14:28:33 +0800 Subject: refactor: rename `function_matcher` to `selected_functions` (#583) --- src/config/bot.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/config/bot.rs') diff --git a/src/config/bot.rs b/src/config/bot.rs index 80d3a5d..a0ea58a 100644 --- a/src/config/bot.rs +++ b/src/config/bot.rs @@ -2,7 +2,7 @@ use super::*; use crate::{ client::Model, - function::{Functions, FUNCTION_ALL_MATCHER}, + function::{Functions, FunctionsFilter, SELECTED_ALL_FUNCTIONS}, }; use anyhow::{Context, Result}; @@ -141,11 +141,11 @@ impl RoleLike for Bot { self.config.top_p } - fn function_matcher(&self) -> Option { + fn selected_functions(&self) -> Option { if self.functions.is_empty() { None } else { - Some(FUNCTION_ALL_MATCHER.into()) + Some(SELECTED_ALL_FUNCTIONS.into()) } } @@ -162,7 +162,7 @@ impl RoleLike for Bot { self.config.top_p = value; } - fn set_function_matcher(&mut self, _value: Option) {} + fn set_selected_functions(&mut self, _value: Option) {} } #[derive(Debug, Clone, Default, Deserialize, Serialize)] -- cgit v1.2.3