MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / mapToStruct

Function mapToStruct

pkg/credentials/vault/keyval.go:200–212  ·  view source on GitHub ↗
(i map[string]interface{}, o interface{})

Source from the content-addressed store, hash-verified

198}
199
200func mapToStruct(i map[string]interface{}, o interface{}) error {
201 b, err := json.Marshal(i)
202 if err != nil {
203 return err
204 }
205
206 err = json.Unmarshal(b, o)
207 if err != nil {
208 return err
209 }
210
211 return nil
212}
213
214func (r Role) String() string {
215 switch r {

Callers 1

ReadCredentialsMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected