from typing import Union
from typing import List


def str_to_list(text: Union[str, None]) -> Union[List, None]:
    """Split string by comma and return list"""

    return text.split(",") if isinstance(text, str) else text