nits: refactor

This commit is contained in:
Jun Kurihara 2025-05-20 22:04:03 +09:00
commit e0ab2d85fb
No known key found for this signature in database
GPG key ID: D992B3E3DE1DED23

View file

@ -1,4 +1,4 @@
use super::toml::ConfigToml;
use super::toml::{ConfigToml, ConfigTomlExt};
use crate::error::{anyhow, ensure};
use ahash::HashMap;
use clap::Arg;
@ -53,8 +53,6 @@ pub fn parse_opts() -> Result<Opts, anyhow::Error> {
})
}
use super::toml::ConfigTomlExt;
/// Build proxy and app settings from config using ConfigTomlExt
pub fn build_settings(config: &ConfigToml) -> Result<(ProxyConfig, AppConfigList), anyhow::Error> {
config.validate_and_build_settings()