chore: bump reva

This commit is contained in:
Florian Schade
2024-02-06 14:55:13 +01:00
committed by jkoberg
parent 6487ed7101
commit c851490399
5 changed files with 12 additions and 6 deletions

View File

@@ -4,9 +4,9 @@ import (
"encoding/json"
)
// SendSEE instructs the sse service to send a notification to a user
// SendSSE instructs the sse service to send one or multiple notifications
type SendSSE struct {
UserID string
UserIDs []string
Type string
Message []byte
}

View File

@@ -50,10 +50,16 @@ func (i *Index) Load(index string) (map[string]string, error) {
}
// Add adds an entry to an index
// Consider calling AddAll() when trying to add multiple entries as every Add call has to lock the index
func (i *Index) Add(index, key string, value string) error {
return i.updateIndex(index, map[string]string{key: value}, []string{})
}
// AddAll adds multiple entries to the index
func (i *Index) AddAll(index string, m map[string]string) error {
return i.updateIndex(index, m, []string{})
}
// Remove removes an entry from the index
func (i *Index) Remove(index, key string) error {
return i.updateIndex(index, map[string]string{}, []string{key})