Skip to content

Commit

Permalink
Allow deleting directories via FileStorage
Browse files Browse the repository at this point in the history
  • Loading branch information
goksan committed Apr 15, 2024
1 parent fb2d9bf commit 949bd41
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion filestorage.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (s *FileStorage) Load(_ context.Context, key string) ([]byte, error) {

// Delete deletes the value at key.
func (s *FileStorage) Delete(_ context.Context, key string) error {
return os.Remove(s.Filename(key))
return os.RemoveAll(s.Filename(key))
}

// List returns all keys that match prefix.
Expand Down

0 comments on commit 949bd41

Please sign in to comment.