From f19ad9bd9d716322fde8752e8e89b95109e325bf Mon Sep 17 00:00:00 2001 From: Pedro Algarvio Date: Wed, 6 Nov 2013 23:10:42 +0000 Subject: [PATCH] Take into account `__env__` and `saltenv` being passed from state files. --- salt/state.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/salt/state.py b/salt/state.py index 69fa966a00..31fdb29195 100644 --- a/salt/state.py +++ b/salt/state.py @@ -1275,9 +1275,11 @@ class State(object): # format_call env = cdata['kwargs']['env'] elif '__env__' in data: - # The user is passing an alternative environement using the - # proper keyword argument + # The user is passing an alternative environment using __env__ + # which is also not the appropriate choice, still, handle it env = data['__env__'] + elif 'saltenv' in data: + env = data['saltenv'] else: # Let's use the default environment env = 'base'