1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

exoscale: fix TXT type records handling (#23956)

This commit is contained in:
René Moser 2017-04-25 13:05:37 +02:00 committed by GitHub
parent f354bd1eab
commit 3959597f7d

View file

@ -276,10 +276,6 @@ class ExoDnsRecord(ExoDns):
def __init__(self, module):
super(ExoDnsRecord, self).__init__(module)
self.content = self.module.params.get('content')
if self.content:
self.content = self.content.lower()
self.domain = self.module.params.get('domain').lower()
self.name = self.module.params.get('name').lower()
if self.name == self.domain:
@ -290,6 +286,10 @@ class ExoDnsRecord(ExoDns):
if self.multiple and self.record_type != 'A':
self.module.fail_json(msg="Multiple is only usable with record_type A")
self.content = self.module.params.get('content')
if self.content and self.record_type != 'TXT':
self.content = self.content.lower()
def _create_record(self, record):
self.result['changed'] = True
data = {