diff options
Diffstat (limited to 'bin/src/config.rs')
-rw-r--r-- | bin/src/config.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bin/src/config.rs b/bin/src/config.rs index 8ddfb4a..c856a59 100644 --- a/bin/src/config.rs +++ b/bin/src/config.rs | |||
@@ -234,9 +234,10 @@ impl FromStr for OutFormat { | |||
234 | match value.to_ascii_lowercase().as_str() { | 234 | match value.to_ascii_lowercase().as_str() { |
235 | #[cfg(feature = "json")] | 235 | #[cfg(feature = "json")] |
236 | "json" => Ok(Self::Json), | 236 | "json" => Ok(Self::Json), |
237 | #[cfg(not(feature = "json"))] | ||
238 | "json" => Err("statix was not compiled with the `json` feature flag"), | ||
237 | "errfmt" => Ok(Self::Errfmt), | 239 | "errfmt" => Ok(Self::Errfmt), |
238 | "stderr" => Ok(Self::StdErr), | 240 | "stderr" => Ok(Self::StdErr), |
239 | "json" => Err("statix was not compiled with the `json` feature flag"), | ||
240 | _ => Err("unknown output format, try: json, errfmt"), | 241 | _ => Err("unknown output format, try: json, errfmt"), |
241 | } | 242 | } |
242 | } | 243 | } |