Add return type

This commit is contained in:
Christian Cueni 2024-07-31 11:14:19 +02:00
parent 46760cf8ae
commit af84a0ee01
1 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,5 @@
from io import BytesIO
from typing import Optional
import structlog
from django.utils.translation import gettext_lazy as _
@ -22,8 +23,8 @@ def export_persons(
user: User,
course_session_ids: list[str],
save_as_file: bool = False,
):
if len(course_session_ids) == 0:
) -> Optional[bytes]:
if not course_session_ids:
return
wb = Workbook()