diff options
author | Ryan Leckey <ryan@launchbadge.com> | 2017-06-14 00:28:43 -0700 |
---|---|---|
committer | Ryan Leckey <ryan@launchbadge.com> | 2017-06-14 00:28:43 -0700 |
commit | 1716c2fe7571b03215a5ae09c91f508d03335c2a (patch) | |
tree | f2b3144044f907c8eb1c594460d6cd74eed92b1f /src/file/source/string.rs | |
parent | 9a2e756075dce24e764c8c89e2d71703a69fd80a (diff) | |
parent | 736738a2a798d58b1a73b0da146924a7e92ceba3 (diff) |
Merge branch 'feature/with_name' of https://github.com/JordiPolo/config-rs into JordiPolo-feature/with_name
Diffstat (limited to 'src/file/source/string.rs')
-rw-r--r-- | src/file/source/string.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/file/source/string.rs b/src/file/source/string.rs index e1d9f64..922e46c 100644 --- a/src/file/source/string.rs +++ b/src/file/source/string.rs @@ -15,7 +15,7 @@ impl<'a> From<&'a str> for FileSourceString { } impl FileSource for FileSourceString { - fn resolve(&self, _: Option<FileFormat>) -> Result<(Option<String>, String), Box<Error>> { - Ok((None, self.0.clone())) + fn resolve(&self, format_hint: Option<FileFormat>) -> Result<(Option<String>, String, FileFormat), Box<Error>> { + Ok((None, self.0.clone(), format_hint.expect("from_str requires a set file format"))) } } |