[PR #6575/f710a10f backport][stable-6] ini_file: try using inactive option before creating a new one (#6728)

ini_file: try using inactive option before creating a new one (#6575)

* ini_file: make inactive options as active if they exist, instead of creating a new option entry

Add changelog fragment

* Update changelogs/fragments/ini_file-use-inactive-options-when-possible.yml

Co-authored-by: Felix Fontein <felix@fontein.de>

* Fix test

* Update tests

* Fix spelling

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit f710a10f25)

Co-authored-by: njutn95 <njutn95@yahoo.com>
This commit is contained in:
patchback[bot] 2023-06-19 08:01:18 +02:00 committed by GitHub
commit 2b88ee01d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 24 additions and 22 deletions

View file

@ -0,0 +1,3 @@
---
bugfixes:
- ini_file - fix a bug where the inactive options were not used when possible (https://github.com/ansible-collections/community.general/pull/6575).