diff --git a/posting/mvcc.go b/posting/mvcc.go index 9dcfaf98a75..a0bfc16f7dc 100644 --- a/posting/mvcc.go +++ b/posting/mvcc.go @@ -417,6 +417,9 @@ func getNew(key []byte, pstore *badger.DB, readTs uint64) (*List, error) { } } + if pstore.IsClosed() { + return nil, badger.ErrDBClosed + } txn := pstore.NewTransactionAt(readTs, false) defer txn.Discard()