<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_charset(self, default: str) -> str: """Returns charset parameter from Content-Type header or default."""

        ctype = self.headers.get(CONTENT_TYPE, '')
        mimetype = parse_mimetype(ctype)
        return mimetype.parameters.get('charset', default)