nextElementStoryId method

String? nextElementStoryId()

Implementation

String? nextElementStoryId() {
  int position =
      storiesIdsList!.indexWhere((id) => id.startsWith(pressedStoryId!));
  if (storiesIdsList!.length == position + 1 || position == -1) {
    return null;
  }
  position++;
  return storiesIdsList![position];
}