websocket backend + frontend patching.
This commit is contained in:
@@ -155,7 +155,7 @@ func (b *Bridge) RefreshAll() ([]lucifer3.Event, error) {
|
||||
}
|
||||
}
|
||||
|
||||
if res.Type == "device" {
|
||||
if res.Type == "device" && !strings.HasPrefix(res.Metadata.Archetype, "bridge") {
|
||||
hwState, hwEvent := res.GenerateEvent(b.host, resources)
|
||||
if hwState.SupportFlags == 0 {
|
||||
continue
|
||||
@@ -219,7 +219,7 @@ func (b *Bridge) ApplyPatches(date time.Time, resources []ResourceData) (eventLi
|
||||
|
||||
for _, resource := range resources {
|
||||
if resource.Owner != nil && resource.Owner.Kind == "device" {
|
||||
if parent, ok := mapCopy[resource.Owner.ID]; ok {
|
||||
if parent, ok := mapCopy[resource.Owner.ID]; ok && !strings.HasPrefix(parent.Metadata.Archetype, "bridge") {
|
||||
hwState, _ := parent.GenerateEvent(b.host, mapCopy)
|
||||
eventList = append(eventList, hwState)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user