import io
import base64


def decode_file(contents):
    """
    Decodes raw file contents and returns it
    :param str contents: File content
    :return: The decoded content
    :rtype: str
    """
    content_type, content_string = contents.split(",")
    decoded = io.BytesIO(base64.b64decode(content_string))
    return decoded