CtxPublicKey pulls the public key out of the context, or nil if not found.
(ctx context.Context)
| 89 | |
| 90 | // CtxPublicKey pulls the public key out of the context, or nil if not found. |
| 91 | func CtxPublicKey(ctx context.Context) *models.PublicKey { |
| 92 | if pk, ok := ctx.Value(contextKeyPublicKey).(*models.PublicKey); ok { |
| 93 | return pk |
| 94 | } |
| 95 | |
| 96 | return nil |
| 97 | } |
no outgoing calls