fix(examples): Offer Storage with non-global client (#489)
This commit is contained in:
parent
7b64687990
commit
7d0cdec925
1 changed files with 4 additions and 0 deletions
|
@ -90,6 +90,10 @@ func (s *publicKey) Key() any {
|
|||
}
|
||||
|
||||
func NewStorage(userStore UserStore) *Storage {
|
||||
return NewStorageWithClients(userStore, clients)
|
||||
}
|
||||
|
||||
func NewStorageWithClients(userStore UserStore, clients map[string]*Client) *Storage {
|
||||
key, _ := rsa.GenerateKey(rand.Reader, 2048)
|
||||
return &Storage{
|
||||
authRequests: make(map[string]*AuthRequest),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue