Skip to content

Commit

Permalink
Don't return a trivial error if source implements nothing we can handle
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexis Destrez authored and krostar committed Jan 25, 2019
1 parent a3173f8 commit b3d28e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion configue.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func (c *Configue) loadSource(source Source, cfg interface{}) error {
} else if s, ok := source.(SourceGetReprValueByKey); ok {
err = reflectThroughConfig(s, cfg)
} else {
err = trivialerr.New("%s does not fulfill any load interface", source.Name())
err = errors.Errorf("%s does not fulfill any load interface", source.Name())
}

if trivialerr.IsTrivial(errors.Cause(err)) {
Expand Down

0 comments on commit b3d28e5

Please sign in to comment.