mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #42884 from Giandom/2017.7.1-fix-slack-engine-pillar-args
Convert to dict type the pillar string value passed from slack
This commit is contained in:
commit
82be9dceb6
1 changed files with 5 additions and 0 deletions
|
@ -61,6 +61,7 @@ import logging
|
|||
import time
|
||||
import re
|
||||
import yaml
|
||||
import ast
|
||||
|
||||
try:
|
||||
import slackclient
|
||||
|
@ -245,6 +246,10 @@ def start(token,
|
|||
tgt_type = kwargs['tgt_type']
|
||||
del kwargs['tgt_type']
|
||||
|
||||
# Check for pillar string representation of dict and convert it to dict
|
||||
if 'pillar' in kwargs:
|
||||
kwargs.update(pillar=ast.literal_eval(kwargs['pillar']))
|
||||
|
||||
ret = {}
|
||||
|
||||
if cmd in runner_functions:
|
||||
|
|
Loading…
Add table
Reference in a new issue