diff --git a/pingora-core/src/server/mod.rs b/pingora-core/src/server/mod.rs index 42735507..75112070 100644 --- a/pingora-core/src/server/mod.rs +++ b/pingora-core/src/server/mod.rs @@ -176,7 +176,8 @@ impl Server { /// /// Command line options can either be passed by parsing the command line arguments via /// `Opt::from_args()`, or be generated by other means. - pub fn new(opt: Option) -> Result { + pub fn new(opt: impl Into>) -> Result { + let opt = opt.into(); let (tx, rx) = watch::channel(false); let conf = if let Some(opt) = opt.as_ref() {