Merge pull request #812 from bonedaddy/master

Fix Issue 811
This commit is contained in:
Simone Margaritelli 2021-01-15 17:56:07 +01:00 committed by GitHub
commit fef32192be
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -67,8 +67,6 @@ func NewWiFi(iface *Endpoint, aliases *data.UnsortedKV, newcb APNewCallback, los
}
func (w *WiFi) MarshalJSON() ([]byte, error) {
w.RLock()
defer w.RUnlock()
doc := wifiJSON{
// we know the length so preallocate to reduce memory allocations