diff --git a/aleksis/apps/cursus/schema.py b/aleksis/apps/cursus/schema.py
index 986be0562e9b12848cb19a518f1797d9ec2690bc..60c9397dd00f7ca1de58978b8c92ba1a6b423f40 100644
--- a/aleksis/apps/cursus/schema.py
+++ b/aleksis/apps/cursus/schema.py
@@ -283,10 +283,7 @@ class Query(graphene.ObjectType):
     def resolve_courses_of_teacher(root, info, teacher=None):
         if not has_person(info.context.user):
             raise PermissionDenied()
-        if teacher:
-            teacher = Person.objects.get(pk=teacher)
-        else:
-            teacher = info.context.user.person
+        teacher = Person.objects.get(pk=teacher) if teacher else info.context.user.person
         # FIXME: Permission checking. But maybe it's done in get_queryset
         return teacher.courses_as_teacher.all()
 
diff --git a/pyproject.toml b/pyproject.toml
index db0c3d51d8db7ad02edd59a47448135928738de8..0a229883233684df0f867b218f33de2c27503df0 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -32,9 +32,10 @@ priority = "primary"
 name = "gitlab"
 url = "https://edugit.org/api/v4/projects/461/packages/pypi/simple"
 priority = "supplemental"
+
 [tool.poetry.dependencies]
 python = "^3.10"
-aleksis-core = "^4.0.0.dev0"
+aleksis-core = "^4.0.0.dev3"
 
 [tool.poetry.plugins."aleksis.app"]
 cursus = "aleksis.apps.cursus.apps:DefaultConfig"