Skip to content

Commit 39e9d60

Browse files
authored
Merge pull request #97 from sahib/fix/close-DBs-on-Quit
fix: the file system `badger db` is now closed on Quit
2 parents 94dfed3 + 65b2027 commit 39e9d60

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

repo/repo.go

+5
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,11 @@ func Open(baseFolder string) (*Repository, error) {
113113
// Close will lock the repository, making this instance unusable.
114114
func (rp *Repository) Close() error {
115115
rp.stopAutoGCLoop()
116+
for owner, fs := range rp.fsMap {
117+
log.Infof("closing FS for %s", owner)
118+
fs.Close()
119+
}
120+
116121
return nil
117122
}
118123

0 commit comments

Comments
 (0)