From 07da3635950c98b0fb81fe8f62fa0bd39757789b Mon Sep 17 00:00:00 2001 From: David Florness Date: Sun, 11 Oct 2020 21:42:23 -0400 Subject: [PATCH] Fix error messages --- config.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/config.go b/config.go index 953ae51..8915292 100644 --- a/config.go +++ b/config.go @@ -68,11 +68,11 @@ func (e *Election) saveInfo() error { } raw, err := marshalElectionInfos(infos) if err != nil { - return fmt.Errorf("unable to marshal election info for caching: %s", err) + return fmt.Errorf("unable to marshal election info for cache file: %s", err) } err = encodeElectionsInfos(file, raw) if err != nil { - return fmt.Errorf("unable to encode election info for caching: %s", err) + return fmt.Errorf("unable to encode election info for cache file: %s", err) } return nil } @@ -105,11 +105,11 @@ func loadPastElectionInfos() (ElectionInfos, error) { defer file.Close() raw, err := decodeElectionInfos(file) if err != nil { - return nil, fmt.Errorf("unable to decode election info for caching: %s", err) + return nil, fmt.Errorf("unable to decode election info for cache file: %s", err) } infos, err := unmarshalRawElectionInfos(raw) if err != nil { - return nil, fmt.Errorf("unable to encode election info for caching: %s", err) + return nil, fmt.Errorf("unable to unmarshal election info for cache file: %s", err) } return infos, nil } -- 2.38.4