From 891489a27e33a94a8daaf8c51d8b6c2cbb2354f2 Mon Sep 17 00:00:00 2001 From: Andrey Klychkov Date: Mon, 21 Oct 2019 17:14:23 +0300 Subject: [PATCH] postgresql_publication: fix logic (#63737) --- .../modules/database/postgresql/postgresql_publication.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/database/postgresql/postgresql_publication.py b/lib/ansible/modules/database/postgresql/postgresql_publication.py index ae431e41ac3..67147b45bd5 100644 --- a/lib/ansible/modules/database/postgresql/postgresql_publication.py +++ b/lib/ansible/modules/database/postgresql/postgresql_publication.py @@ -638,7 +638,7 @@ def main(): # Get final publication info: pub_fin_info = {} - if state != 'absent' or (state == 'absent' and module.check_mode): + if state == 'present' or (state == 'absent' and module.check_mode): pub_fin_info = publication.get_info() elif state == 'absent' and not module.check_mode: publication.exists = False