Skip to content

Instantly share code, notes, and snippets.

@agraul
Last active October 27, 2021 16:09
Show Gist options
  • Save agraul/3b779d9a14278c085c0e32bad6015f14 to your computer and use it in GitHub Desktop.
Save agraul/3b779d9a14278c085c0e32bad6015f14 to your computer and use it in GitHub Desktop.
modules/state.py diff
diff --git a/salt/modules/state.py b/salt/modules/state.py
index b439f79e57e..71ba499ffb6 100644
--- a/salt/modules/state.py
+++ b/salt/modules/state.py
@@ -118,7 +118,7 @@ def _get_pillar_errors(kwargs, pillar=None):
return (
None
if kwargs.get("force")
- else (pillar or {}).get("_errors", __pillar__.get("_errors")) or None
+ else (pillar or __pillar__).get("_errors", None)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment