update
This commit is contained in:
Regular → Executable
+2
-2
@@ -133,12 +133,12 @@ Base.@kwdef mutable struct mqttClient
|
||||
retainedMsgCleared= false
|
||||
keepalive::Int= 60
|
||||
end
|
||||
function mqttClient(kwargs::NamedTuple)
|
||||
function mqttClient(mqttClientSpec::NamedTuple)
|
||||
|
||||
# instantiate client data struct
|
||||
s = mqttClient()
|
||||
|
||||
for (k, v) in pairs(kwargs)
|
||||
for (k, v) in pairs(mqttClientSpec)
|
||||
s.:($k) = v
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user