Skip to content

Commit ec7c4d2

Browse files
authored
refactor: do not use _ as functional variable name (#268)
1 parent 2239b0b commit ec7c4d2

1 file changed

Lines changed: 14 additions & 4 deletions

File tree

hcloud/firewalls/client.py

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,8 @@ def create(
333333
actions = []
334334
if response.get("actions") is not None:
335335
actions = [
336-
BoundAction(self._client.actions, _) for _ in response["actions"]
336+
BoundAction(self._client.actions, action_data)
337+
for action_data in response["actions"]
337338
]
338339

339340
result = CreateFirewallResponse(
@@ -401,7 +402,10 @@ def set_rules(
401402
method="POST",
402403
json=data,
403404
)
404-
return [BoundAction(self._client.actions, _) for _ in response["actions"]]
405+
return [
406+
BoundAction(self._client.actions, action_data)
407+
for action_data in response["actions"]
408+
]
405409

406410
def apply_to_resources(
407411
self,
@@ -422,7 +426,10 @@ def apply_to_resources(
422426
method="POST",
423427
json=data,
424428
)
425-
return [BoundAction(self._client.actions, _) for _ in response["actions"]]
429+
return [
430+
BoundAction(self._client.actions, action_data)
431+
for action_data in response["actions"]
432+
]
426433

427434
def remove_from_resources(
428435
self,
@@ -443,4 +450,7 @@ def remove_from_resources(
443450
method="POST",
444451
json=data,
445452
)
446-
return [BoundAction(self._client.actions, _) for _ in response["actions"]]
453+
return [
454+
BoundAction(self._client.actions, action_data)
455+
for action_data in response["actions"]
456+
]

0 commit comments

Comments
 (0)