mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Black
This commit is contained in:
parent
047fdc92a8
commit
bdf7316ca3
1 changed files with 3 additions and 3 deletions
|
@ -1189,11 +1189,11 @@ def get_name(principal):
|
|||
# All capability SIDs begin with `S-1-15-3`, so we'll only throw an
|
||||
# error when the sid does not begin with `S-1-15-3`
|
||||
str_sid = get_sid_string(sid_obj)
|
||||
if not str_sid.startswith('S-1-15-3'):
|
||||
if not str_sid.startswith("S-1-15-3"):
|
||||
message = 'Error resolving "{0}"'.format(principal)
|
||||
if type(exc) == pywintypes.error:
|
||||
win_error = win32api.FormatMessage(exc.winerror).rstrip('\n')
|
||||
message = '{0}: {1}'.format(message, win_error)
|
||||
win_error = win32api.FormatMessage(exc.winerror).rstrip("\n")
|
||||
message = "{0}: {1}".format(message, win_error)
|
||||
log.exception(message)
|
||||
raise CommandExecutionError(message, exc)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue