diff --git a/ucs-school-umc-wizards/umc/python/schoolwizards/__init__.py b/ucs-school-umc-wizards/umc/python/schoolwizards/__init__.py index 50256d3..ab5e282 100644 --- a/ucs-school-umc-wizards/umc/python/schoolwizards/__init__.py +++ b/ucs-school-umc-wizards/umc/python/schoolwizards/__init__.py @@ -38,7 +38,7 @@ from univention.lib.i18n import Translation from univention.management.console.log import MODULE from univention.management.console.modules.decorators import simple_response, sanitize from univention.management.console.modules.sanitizers import StringSanitizer -from univention.admin.uexceptions import base as uldapBaseException +from univention.admin.uexceptions import base as uldapBaseException, noObject import univention.admin.modules as udm_modules from ucsschool.lib.schoolldap import SchoolBaseModule, LDAP_Connection, USER_READ, USER_WRITE @@ -228,7 +228,10 @@ class Instance(SchoolBaseModule, SchoolImport): schools = School.from_binddn(lo) objs = [] for school in schools: - objs.extend(klass.get_all(lo, school.name, filter_str=filter_str, easy_filter=True)) + try: + objs.extend(klass.get_all(lo, school.name, filter_str=filter_str, easy_filter=True)) + except noObject: + pass return [obj.to_dict() for obj in objs] @response