changed config load
This commit is contained in:
@@ -1,14 +1,6 @@
|
||||
use config::Config;
|
||||
use serde::Deserialize;
|
||||
|
||||
use crate::models::WatcherConfig;
|
||||
|
||||
#[derive(Debug, Deserialize, Clone)]
|
||||
pub struct AppConfig {
|
||||
pub watcher: WatcherConfig,
|
||||
}
|
||||
|
||||
impl AppConfig {
|
||||
impl WatcherConfig {
|
||||
pub fn from_env() -> Result<Self, config::ConfigError> {
|
||||
// Load .env file (works in both Docker and local development)
|
||||
dotenvy::dotenv().ok();
|
||||
|
Reference in New Issue
Block a user