Skip to content

Commit

Permalink
fix: remove unused function parameter "config_gen"
Browse files Browse the repository at this point in the history
  • Loading branch information
XargsUK committed Feb 25, 2024
1 parent 2105350 commit 5bd31fd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lambda_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def main_handler(event, context):
configs = {role_name: {'awscli': '', 'awscli_prefixed': '', 'browser_plugin': ''} for role_name in config['role_names']}

for payer_account_id in config['payer_account_ids']:
accounts = aws.process_accounts_for_payer(payer_account_id, config, account_ou_mapping, config_gen)
accounts = aws.process_accounts_for_payer(payer_account_id, config, account_ou_mapping)
if not accounts:
continue
for role_name in config['role_names']:
Expand Down
2 changes: 1 addition & 1 deletion library/aws.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ def process_ous(org_client, parent_id, account_ou_mapping, parent_name, ou_overr
# Recursively process any child OUs
process_ous(org_client, ou['Id'], account_ou_mapping, new_parent_name, ou_overrides)

def process_accounts_for_payer(payer_account_id, config, account_ou_mapping, config_gen):
def process_accounts_for_payer(payer_account_id, config, account_ou_mapping):
assume_role_arn = f"arn:aws:iam::{payer_account_id}:role/{config['assume_role_name']}"
credentials = assume_role(assume_role_arn, config['session_name'] + payer_account_id)
if not credentials:
Expand Down

0 comments on commit 5bd31fd

Please sign in to comment.