hotfix app crash, bump to 2.0.1

This commit is contained in:
Odweta
2024-10-25 16:44:05 +02:00
parent b9f19b93f4
commit 8a4956e6c6
10 changed files with 381 additions and 5 deletions
@@ -85,6 +85,18 @@ fun isTimeBetween(givenTime: LocalTime, startTime: LocalTime, endTime: LocalTime
@SuppressLint("ModifierFactoryExtensionFunction")
@Composable
fun subjectModifier(d: Day, s: Subject, lectureNumber: Int): Modifier {
var day = d.date.split(".")[0].replace(" ", "")
var month = d.date.split(".")[1].replace(" ", "")
if (day.length < 2) {
day = "0$day"
}
if (month.length < 2) {
month = "0$month"
}
d.date = "$day. $month."
val dayFormatter = DateTimeFormatter.ofPattern("dd. MM. yyyy")
val hourFormatter = DateTimeFormatter.ofPattern("HH:mm:ss")
val dateParsed = LocalDate.parse(d.date + " " + LocalDate.now().year, dayFormatter)