Browse Source

Fix Logical operator (#2143)

### What problem does this PR solve?

#2120 

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
tags/v0.11.0
H 1 year ago
parent
commit
527ebec2f5
No account linked to committer's email address
1 changed files with 0 additions and 2 deletions
  1. 0
    2
      agent/component/switch.py

+ 0
- 2
agent/component/switch.py View File

@@ -42,8 +42,6 @@ class SwitchParam(ComponentParamBase):
self.check_empty(self.conditions, "[Switch] conditions")
for cond in self.conditions:
if not cond["to"]: raise ValueError(f"[Switch] 'To' can not be empty!")
if cond["logical_operator"] not in ["and", "or"] and len(cond["items"]) > 1:
raise ValueError(f"[Switch] Please set logical_operator correctly!")


class Switch(ComponentBase, ABC):

Loading…
Cancel
Save