mirror of
https://github.com/cwinfo/matterbridge.git
synced 2025-09-11 07:42:30 +00:00
Update direct dependencies where possible
This commit is contained in:
13
vendor/github.com/magiconair/properties/properties.go
generated
vendored
13
vendor/github.com/magiconair/properties/properties.go
generated
vendored
@@ -1,4 +1,4 @@
|
||||
// Copyright 2017 Frank Schroeder. All rights reserved.
|
||||
// Copyright 2018 Frank Schroeder. All rights reserved.
|
||||
// Use of this source code is governed by a BSD-style
|
||||
// license that can be found in the LICENSE file.
|
||||
|
||||
@@ -83,6 +83,17 @@ func NewProperties() *Properties {
|
||||
}
|
||||
}
|
||||
|
||||
// Load reads a buffer into the given Properties struct.
|
||||
func (p *Properties) Load(buf []byte, enc Encoding) error {
|
||||
l := &Loader{Encoding: enc, DisableExpansion: p.DisableExpansion}
|
||||
newProperties, err := l.LoadBytes(buf)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
p.Merge(newProperties)
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get returns the expanded value for the given key if exists.
|
||||
// Otherwise, ok is false.
|
||||
func (p *Properties) Get(key string) (value string, ok bool) {
|
||||
|
Reference in New Issue
Block a user