1
0
mirror of https://github.com/wulkanowy/wulkanowy.git synced 2024-09-19 23:29:08 -05:00

Add isAdded check in AdditionalLessonAddDialog (#2515)

This commit is contained in:
Rafał Borcz 2024-04-08 20:51:05 +02:00 committed by GitHub
parent b500d8e204
commit 7a3a97447f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -155,7 +155,9 @@ class AdditionalLessonAddDialog : BaseDialogFragment<DialogAdditionalAddBinding>
.build()
timePicker.addOnPositiveButtonClickListener {
onTimeSelected(LocalTime.of(timePicker.hour, timePicker.minute))
if (isAdded) {
onTimeSelected(LocalTime.of(timePicker.hour, timePicker.minute))
}
}
if (!parentFragmentManager.isStateSaved) {