Проверка шаблона шины для iOS
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

isToggle.py 518B

10 months ago
1234567891011121314
  1. def isToggle(name, structure):
  2. # Проверяем наличие `toggle` в свойствах канала ядра.
  3. if name in structure.core.pipes:
  4. props = structure.core.pipes[name]
  5. if "toggle" in props:
  6. return True
  7. # Проверяем наличие `toggle` в свойствах канала сервиса.
  8. if name in structure.service.pipes:
  9. props = structure.service.pipes[name]
  10. if "toggle" in props:
  11. return True
  12. return False