hyper_scripter/
my_env_logger.rs1use log::SetLoggerError;
2
3pub fn try_init() -> Result<(), SetLoggerError> {
4 #[cfg(feature = "log")]
5 {
6 env_logger::try_init()
7 }
8 #[cfg(feature = "no-log")]
9 {
10 Ok(())
11 }
12}
13
14pub fn init() {
15 #[cfg(feature = "log")]
16 env_logger::init();
17}