def path_type(path, target):
    """
    Determine if given path is file, directory, or other. Compare with target to see if it's the type we wanted.

    :param str path: Path
    :param str target: Target type wanted
    :return bool: Path is what it claims to be (True) or mismatch (False)
    """
    if os.path.isfile(path) and target == "file":
        return True
    elif os.path.isdir(path) and target == "directory":
        return True
    else:
        print("Error: Path given is not a {}: {}".format(target, path))
    return False
Determine if given path is file, directory, or other. Compare with target to see if it's the type we wanted.

    :param str path: Path
    :param str target: Target type wanted
    :return bool: Path is what it claims to be (True) or mismatch (False)