We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 59a7719 commit 4404dc3Copy full SHA for 4404dc3
arduino/discovery/discovery.go
@@ -65,12 +65,16 @@ type Port struct {
65
66
// ToRPC converts Port into rpc.Port
67
func (p *Port) ToRPC() *rpc.Port {
68
+ props := p.Properties
69
+ if props == nil {
70
+ props = properties.NewMap()
71
+ }
72
return &rpc.Port{
73
Address: p.Address,
74
Label: p.AddressLabel,
75
Protocol: p.Protocol,
76
ProtocolLabel: p.ProtocolLabel,
- Properties: p.Properties.AsMap(),
77
+ Properties: props.AsMap(),
78
}
79
80
0 commit comments