mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #42573 from rallytime/bp-42433
Back-port #42433 to 2016.11
This commit is contained in:
commit
9e0b4e9faf
1 changed files with 2 additions and 2 deletions
|
@ -263,14 +263,14 @@ def _get_opts(**kwargs):
|
|||
|
||||
if 'saltenv' in kwargs:
|
||||
saltenv = kwargs['saltenv']
|
||||
if not isinstance(saltenv, six.string_types):
|
||||
if saltenv is not None and not isinstance(saltenv, six.string_types):
|
||||
opts['environment'] = str(kwargs['saltenv'])
|
||||
else:
|
||||
opts['environment'] = kwargs['saltenv']
|
||||
|
||||
if 'pillarenv' in kwargs:
|
||||
pillarenv = kwargs['pillarenv']
|
||||
if not isinstance(pillarenv, six.string_types):
|
||||
if pillarenv is not None and not isinstance(pillarenv, six.string_types):
|
||||
opts['pillarenv'] = str(kwargs['pillarenv'])
|
||||
else:
|
||||
opts['pillarenv'] = kwargs['pillarenv']
|
||||
|
|
Loading…
Add table
Reference in a new issue