<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def transaction_error_code(self):
 """The machine-readable error code for a transaction error."""

        error = self.response_doc.find('transaction_error')
        if error is not None:
            code = error.find('error_code')
            if code is not None:
                return code.text