mirror of
https://github.com/anyproto/any-sync.git
synced 2025-06-08 14:07:02 +09:00
Read keys on storage start
This commit is contained in:
parent
1f3c2b98cf
commit
3fde9b9ef8
1 changed files with 6 additions and 2 deletions
|
@ -82,7 +82,7 @@ func New(
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return &storage{
|
||||
s := &storage{
|
||||
inner: inner,
|
||||
keys: keys,
|
||||
storageId: storageId,
|
||||
|
@ -90,7 +90,11 @@ func New(
|
|||
indexer: indexer,
|
||||
syncClient: syncClient,
|
||||
readKeys: make(map[string]crypto.SymKey),
|
||||
}, nil
|
||||
}
|
||||
s.aclList.RLock()
|
||||
defer s.aclList.RUnlock()
|
||||
err = s.readKeysFromAclState(s.aclList.AclState())
|
||||
return s, err
|
||||
}
|
||||
|
||||
func (s *storage) Id() string {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue