doc: add a note about concurent Get/Set to godoc

This commit is contained in:
Chris Waldon 2021-04-13 09:12:40 -04:00 committed by GitHub
parent ecd1671938
commit cad06b314f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -176,6 +176,8 @@ func DecodeHook(hook mapstructure.DecodeHookFunc) DecoderConfigOption {
// "user": "root",
// "endpoint": "https://localhost"
// }
//
// Note: Vipers are not safe for concurrent Get() and Set() operations.
type Viper struct {
// Delimiter that separates a list of keys
// used to access a nested value in one go