diff --git a/program/views.py b/program/views.py
index b6c6bb785b0cc8e7a012f884b89347c12560b60d..7a8cdd9af8da516e509617f9e49c2cf5d172fe7d 100644
--- a/program/views.py
+++ b/program/views.py
@@ -475,9 +475,9 @@ class APIScheduleViewSet(viewsets.ModelViewSet):
         # If we're updating the default playlist id
         # TODO: If nothing else than default_playlist_id, or is_repetition changed -> just save and don't do anything
         new_schedule = request.data.get('schedule')
-        if 'default_playlist_id' in new_schedule:
+        if default_playlist_id := new_schedule.get('default_playlist_id'):
             schedule = get_object_or_404(Schedule, pk=pk, show=show_pk)
-            schedule.default_playlist_id = int(new_schedule['default_playlist_id'])
+            schedule.default_playlist_id = int(default_playlist_id)
             schedule.save()
 
             serializer = ScheduleSerializer(schedule)