Fixed shortcoming in docs.

Added a comment in the docs about how to make Config not error out
if a configuration file isn't present.
This commit is contained in:
Elf M. Sternberg 2023-03-24 07:54:07 -07:00
parent 727ad252cc
commit 2aa202d05c
1 changed files with 2 additions and 1 deletions

View File

@ -273,7 +273,8 @@ impl Default for Settings {
``` ```
Again, exceeding the book's parameters, I'm going to say that if the file is Again, exceeding the book's parameters, I'm going to say that if the file is
missing the default parameters should hold: missing the default parameters should hold, so the presence of a valid
configuration isn't a show-stopper and should not be required.
``` rust ``` rust
pub(crate) fn get_configuration() -> Result<Settings, config::ConfigError> { pub(crate) fn get_configuration() -> Result<Settings, config::ConfigError> {