1
0
mirror of https://github.com/wulkanowy/wulkanowy.git synced 2024-09-20 03:49:09 -05:00

Ignore no current student during avatar loading (#1210)

This commit is contained in:
Rafał Borcz 2021-03-13 20:13:37 +01:00 committed by GitHub
parent 94957850c3
commit 8d7110735d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -113,7 +113,7 @@ class MainPresenter @Inject constructor(
private fun showCurrentStudentAvatar() {
val currentStudent =
studentsWitSemesters!!.single { it.student.isCurrent }.student
studentsWitSemesters?.singleOrNull { it.student.isCurrent }?.student ?: return
view?.showStudentAvatar(currentStudent)
}