Skip to content

Refactor: combine multiple set_fact into single jinja filter #846

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 8, 2025

Conversation

Tinyblargon
Copy link
Contributor

Replaced 3 set_fact blocks with a single jinja filter, reducing the amount of redundant tasks to be displayed.

We can directly use the transformed result and don't have to mutate sysctl_config as it's only used once.

default({}) creates an empty dict, ommiting the {} would result in the wrong type.

Signed-off-by: Tinyblargon <76069640+Tinyblargon@users.noreply.github.com>
@schurzi schurzi added the patch label Feb 8, 2025
@schurzi schurzi merged commit 2372abd into dev-sec:master Feb 8, 2025
30 checks passed
@schurzi
Copy link
Contributor

schurzi commented Feb 8, 2025

nice one, thank you @Tinyblargon!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants