mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 13:22:48 +00:00
[PR #10727/6f40eff6 backport][stable-11] simplify string formatting in some modules (#10773)
simplify string formatting in some modules (#10727)
* simplify string formatting in some modules
* add changelog frag
(cherry picked from commit 6f40eff632)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
@@ -210,7 +210,7 @@ def main():
|
||||
rc, stdout, stderr = db_import(conn, cursor, module, db, target)
|
||||
|
||||
if rc != 0:
|
||||
module.fail_json(msg="%s" % stderr)
|
||||
module.fail_json(msg=stderr)
|
||||
else:
|
||||
module.exit_json(changed=True, db=db, msg=stdout)
|
||||
else:
|
||||
@@ -229,7 +229,7 @@ def main():
|
||||
rc, stdout, stderr = db_import(conn, cursor, module, db, target)
|
||||
|
||||
if rc != 0:
|
||||
module.fail_json(msg="%s" % stderr)
|
||||
module.fail_json(msg=stderr)
|
||||
else:
|
||||
module.exit_json(changed=True, db=db, msg=stdout)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user