Skip to content

Commit 92c8019

Browse files
committed
fix: flake8 linting error due to conditionals
1 parent 6958939 commit 92c8019

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

app/api/v2/managers/operation_api_manager.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,9 @@ async def _construct_and_dump_source(self, source_id: str):
174174

175175
async def _call_ability_plugin_hooks(self, ability, executor):
176176
"""Calls any plugin hooks (at runtime) that exist for the ability and executor."""
177-
if hasattr(executor, 'HOOKS') and executor.HOOKS and \
178-
hasattr(executor, 'language') and executor.language and \
179-
executor.language in executor.HOOKS:
177+
if (hasattr(executor, 'HOOKS') and executor.HOOKS and
178+
hasattr(executor, 'language') and executor.language and
179+
executor.language in executor.HOOKS):
180180
await executor.HOOKS[executor.language](ability, executor)
181181

182182
async def validate_operation_state(self, data: dict, existing: Operation = None):

app/service/planning_svc.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -392,9 +392,9 @@ async def _generate_cleanup_links(self, operation, agent, link_status):
392392

393393
async def _call_ability_plugin_hooks(self, ability, executor):
394394
"""Calls any plugin hooks (at runtime) that exist for the ability and executor."""
395-
if hasattr(executor, 'HOOKS') and executor.HOOKS and \
396-
hasattr(executor, 'language') and executor.language and \
397-
executor.language in executor.HOOKS:
395+
if (hasattr(executor, 'HOOKS') and executor.HOOKS and
396+
hasattr(executor, 'language') and executor.language and
397+
executor.language in executor.HOOKS):
398398
await executor.HOOKS[executor.language](ability, executor)
399399

400400
@staticmethod

0 commit comments

Comments
 (0)