<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def update_record(self, domain, record, record_type=None, name=None):
 """Call to GoDaddy API to update a single DNS record :param name: only required if the record is None (deletion) :param record_type: only required if the record is None (deletion) :param domain: the domain where the DNS belongs to (eg. 'example.com') :param record: dict with record info (ex. {'name': 'dynamic', 'ttl': 3600, 'data': '1.1.1.1', 'type': 'A'}) :return: True if no exceptions occurred """

        if record_type is None:
            record_type = record['type']
        if name is None:
            name = record['name']

        url = self.API_TEMPLATE + self.RECORDS_TYPE_NAME.format(domain=domain, type=record_type, name=name)
        self._put(url, json=[record])
        self.logger.info(
            'Updated record. Domain {} name {} type {}'.format(domain, str(record['name']), str(record['type'])))

        # If we didn't get any exceptions, return True to let the user know
        return True