docs: def _adjust_count_if_required(start_int, count_int, total_int):
      """Adjust requested object count down if there are not enough objects visible to the
      active subjects to cover the requested slice start and count.
  
      Preconditions: start is verified to be lower than the number of visible objects,
      making it possible to create a valid slice by adjusting count.
  
      """
      if start_int + count_int > total_int:
          count_int = total_int - start_int
      count_int = min(count_int, django.conf.settings.MAX_SLICE_ITEMS)
      return count_int