chore(all): review error wrappings
- remove repetitive `cannot` and `failed` prefixes - rename `unmarshaling` to `decoding`
This commit is contained in:
@@ -17,12 +17,12 @@ func (e *Extractor) Data(filepath string) (lines []string,
|
||||
connection models.Connection, err error) {
|
||||
lines, err = readCustomConfigLines(filepath)
|
||||
if err != nil {
|
||||
return nil, connection, fmt.Errorf("cannot read configuration file: %w", err)
|
||||
return nil, connection, fmt.Errorf("reading configuration file: %w", err)
|
||||
}
|
||||
|
||||
connection, err = extractDataFromLines(lines)
|
||||
if err != nil {
|
||||
return nil, connection, fmt.Errorf("cannot extract connection from file: %w", err)
|
||||
return nil, connection, fmt.Errorf("extracting connection from file: %w", err)
|
||||
}
|
||||
|
||||
return lines, connection, nil
|
||||
|
||||
Reference in New Issue
Block a user