log on missing key

This commit is contained in:
A.Unger
2020-02-03 12:56:17 +01:00
parent b574230285
commit f5ae339125
+1 -1
View File
@@ -76,7 +76,7 @@ func (s Store) Write(rec *mstore.Record) error {
path := filepath.Join(s.mountPath, rec.Key)
if len(rec.Key) < 1 {
// TODO log error: empty key
s.Logger.Error().Msg("key cannot be empty")
return fmt.Errorf("%v", "key is empty")
}