Skip to content

Первая версия решения#1

Open
Polyakov-Nikita wants to merge 2 commits intomainfrom
develop
Open

Первая версия решения#1
Polyakov-Nikita wants to merge 2 commits intomainfrom
develop

Conversation

@Polyakov-Nikita
Copy link
Owner

No description provided.

Copy link

@kesch9 kesch9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Хорошая работа

}

public List<TrainingSession> getTrainingSessionsForDayAndTime(DayOfWeek dayOfWeek, TimeOfDay timeOfDay) {
return timetable.get(dayOfWeek).get(timeOfDay);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Если у вас в Map нет записи по dayOfWeek будет ошибка NPE.
Также если нет записи, то нужно вернуть пустой список вместо null

}

public Map<TimeOfDay, List<TrainingSession>> getTrainingSessionsForDay(DayOfWeek dayOfWeek) {
return timetable.get(dayOfWeek);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Если записи нет, то вернется null, лучше вернуть пустой список

@Polyakov-Nikita
Copy link
Owner Author

Извините за дурацкий вопрос. Я запушил изменения в ветку, они отобразились? Или надо новый pull request делать с правками?

Copy link

@kesch9 kesch9 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approve

@kesch9
Copy link

kesch9 commented Dec 16, 2025

Извините за дурацкий вопрос. Я запушил изменения в ветку, они отобразились? Или надо новый pull request делать с правками?

Всё отобразилось, не нужно делать новый PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants