Fix inline code related lint issues.

This commit is contained in:
Pedro Algarvio 2014-01-06 17:11:20 +00:00
parent 3af5f5d6aa
commit ec2f78146c

View File

@ -25,9 +25,9 @@ def __virtual__():
'''
Most everything has the ability to support at(1)
'''
if salt.utils.is_windows() or not salt.utils.which('at'):
if salt.utils.is_windows() or salt.utils.which('at') is None:
return False
return 'at'
return True
def _cmd(binary, *args):
@ -284,33 +284,54 @@ def _atq(**kwargs):
for job in jobinfo:
if not runas: pass
elif runas == job['user']: pass
else: continue
if not runas:
pass
elif runas == job['user']:
pass
else:
continue
if not tag: pass
elif tag == job['tag']: pass
else: continue
if not tag:
pass
elif tag == job['tag']:
pass
else:
continue
if not hour: pass
elif "%02d" % int(hour) == job['time'].split(':')[0]: pass
else: continue
if not hour:
pass
elif "%02d" % int(hour) == job['time'].split(':')[0]:
pass
else:
continue
if not minute: pass
elif "%02d" % int(minute) == job['time'].split(':')[1]: pass
else: continue
if not minute:
pass
elif "%02d" % int(minute) == job['time'].split(':')[1]:
pass
else:
continue
if not day: pass
elif "%02d" % int(day) == job['date'].split('-')[2]: pass
else: continue
if not day:
pass
elif "%02d" % int(day) == job['date'].split('-')[2]:
pass
else:
continue
if not month: pass
elif "%02d" % int(month) == job['date'].split('-')[1]: pass
else: continue
if not month:
pass
elif "%02d" % int(month) == job['date'].split('-')[1]:
pass
else:
continue
if not year: pass
elif year == job['date'].split('-')[0]: pass
else: continue
if not year:
pass
elif year == job['date'].split('-')[0]:
pass
else:
continue
jobs.append(job)