<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def check_dependencies(dependencies, module):
 """ Ensure dependencies of a module are listed in settings.INSTALLED_APPS :dependencies string | list: list of dependencies to check :module string: string representing the path to the current app """

    if type(dependencies) == str:
        dependencies = [dependencies]
    elif type(dependencies) != list:
        raise TypeError('dependencies argument must be of type list or string')

    for dependency in dependencies:
        if dependency not in settings.INSTALLED_APPS:
            raise DependencyError('%s depends on %s, which should be in settings.INSTALLED_APPS' % (module, dependency))