diff --git a/altsrc/json_source_context.go b/altsrc/json_source_context.go index 0215ced..6e7bf11 100644 --- a/altsrc/json_source_context.go +++ b/altsrc/json_source_context.go @@ -19,9 +19,9 @@ func NewJSONSourceFromFlagFunc(flag string) func(c *cli.Context) (InputSourceCon return func(context *cli.Context) (InputSourceContext, error) { if context.IsSet(flag) { return NewJSONSourceFromFile(context.String(flag)) - } else { - return defaultInputSource() } + + return defaultInputSource() } } diff --git a/altsrc/toml_file_loader.go b/altsrc/toml_file_loader.go index 5c7914a..9b86ee1 100644 --- a/altsrc/toml_file_loader.go +++ b/altsrc/toml_file_loader.go @@ -90,9 +90,9 @@ func NewTomlSourceFromFlagFunc(flagFileName string) func(context *cli.Context) ( if context.IsSet(flagFileName) { filePath := context.String(flagFileName) return NewTomlSourceFromFile(filePath) - } else { - return defaultInputSource() } + + return defaultInputSource() } } diff --git a/altsrc/yaml_file_loader.go b/altsrc/yaml_file_loader.go index 7c5ea19..a49df56 100644 --- a/altsrc/yaml_file_loader.go +++ b/altsrc/yaml_file_loader.go @@ -36,9 +36,9 @@ func NewYamlSourceFromFlagFunc(flagFileName string) func(context *cli.Context) ( if context.IsSet(flagFileName) { filePath := context.String(flagFileName) return NewYamlSourceFromFile(filePath) - } else { - return defaultInputSource() } + + return defaultInputSource() } }