mirror of
https://github.com/mjl-/mox.git
synced 2025-07-10 07:54:40 +03:00
update to latest bstore (with support for an index on a []string: Message.DKIMDomains), and cyclic data types (to be used for Message.Part soon); also adds a context.Context to database operations.
This commit is contained in:
4
main.go
4
main.go
@ -1879,7 +1879,7 @@ func cmdEnsureParsed(c *cmd) {
|
||||
}()
|
||||
|
||||
n := 0
|
||||
err = a.DB.Write(func(tx *bstore.Tx) error {
|
||||
err = a.DB.Write(context.Background(), func(tx *bstore.Tx) error {
|
||||
q := bstore.QueryTx[store.Message](tx)
|
||||
q.FilterFn(func(m store.Message) bool {
|
||||
return all || m.ParsedBuf == nil
|
||||
@ -1952,7 +1952,7 @@ func cmdBumpUIDValidity(c *cmd) {
|
||||
}()
|
||||
|
||||
var uidvalidity uint32
|
||||
err = a.DB.Write(func(tx *bstore.Tx) error {
|
||||
err = a.DB.Write(context.Background(), func(tx *bstore.Tx) error {
|
||||
mb, err := bstore.QueryTx[store.Mailbox](tx).FilterEqual("Name", args[1]).Get()
|
||||
if err != nil {
|
||||
return fmt.Errorf("looking up mailbox: %v", err)
|
||||
|
Reference in New Issue
Block a user