Skip to content

Commit

Permalink
[FIX] paging
Browse files Browse the repository at this point in the history
  • Loading branch information
mallycrip committed Apr 8, 2021
1 parent 3f7fe48 commit a3f5135
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions service/mapper/teacher_outing_mapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@ class TeacherOutingMapper:
def get_outings_for_teacher_mapper(self, outings: List["Outing"], x_request_id, start, count):
outings_proto = []
student_repository: StudentRepository = StudentRepositoryImpl()
if count == 0: start, count = None, None
for outing in outings[start:start+count]:
sc = start + count
if count == 0: sc = None
for outing in outings[start:sc]:
outing_proto = OutingProto()
student = student_repository.find_by_uuid(outing.student_uuid, x_request_id)

Expand Down

0 comments on commit a3f5135

Please sign in to comment.