cleanup after commit
This commit is contained in:
parent
5e553b4a89
commit
8a8a6e50b4
@ -117,5 +117,13 @@ func (s *Store) CommitTemp(path string, sumb []string) error {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
for _, sb := range sumb {
|
||||
dir := s.Dir(tmpdir, sb)
|
||||
filename := filepath.Join(dir, sb)
|
||||
if err := os.Remove(filename); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return os.RemoveAll(filepath.Join(s.Path, tmpdir))
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user