groupware: minor fix for the mock addressbook supplier

This commit is contained in:
Pascal Bleser
2026-06-11 15:42:46 +02:00
parent 798ee91a7a
commit 0fb8496cfb
2 changed files with 4 additions and 3 deletions

View File

@@ -30,13 +30,13 @@ var MockContactCardSupplierInstance *MockContactCardSupplier = &MockContactCardS
},
contacts: []jmap.ContactCard{
{
Id: "alan",
Id: "mock:alan",
AddressBookIds: map[string]bool{"mock:1": true},
Type: jscontact.ContactCardType,
Version: jmap.DEFAULT_CONTACT_CARD_VERSION,
Created: mustParseTime("2026-05-26T10:21:00.000Z"),
Kind: jscontact.ContactCardKindIndividual,
ProdId: "OC",
ProdId: "OC:mock",
Uid: "dc2858d2-4826-412d-afc9-c4492f8f84bc",
Updated: mustParseTime("2026-05-26T10:21:00.000Z"),
Name: &jscontact.Name{

View File

@@ -5,7 +5,6 @@ import (
"encoding/json"
"fmt"
"slices"
"strings"
"time"
"github.com/opencloud-eu/opencloud/pkg/jmap"
@@ -405,6 +404,7 @@ func combineState[K ~string, S jmap.State | jmap.SessionState](m map[K]S) (S, er
}
}
/*
func splitState[K ~string, S jmap.State | jmap.SessionState](state S) (map[K]S, error) {
s := string(state)
if strings.HasPrefix(s, combinedStateEncodingPrefix) {
@@ -422,3 +422,4 @@ func splitState[K ~string, S jmap.State | jmap.SessionState](state S) (map[K]S,
return map[K]S{K("jmap"): state}, nil
}
}
*/