Skip to content

Commit

Permalink
Merge pull request #97 from sandboxing/bquenaudon.2022-04-19.typos
Browse files Browse the repository at this point in the history
Fix some typos and indention
  • Loading branch information
martinbonnin authored Apr 19, 2022
2 parents 8e03dbd + f66b177 commit 2f70064
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ import fr.paug.androidmakers.ui.viewmodel.LceViewModel
import fr.paug.androidmakers.util.EmojiUtils
import fr.paug.androidmakers.util.TimeUtils
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.map
import java.text.DateFormat
import java.util.*

Expand Down Expand Up @@ -71,7 +70,7 @@ fun AgendaLayout(
}
}

class AgendLayoutViewModel: LceViewModel<Agenda>() {
class AgendaLayoutViewModel: LceViewModel<Agenda>() {
override fun produce(): Flow<Result<Agenda>> {
return AndroidMakersApplication.instance().store.getAgenda()
}
Expand All @@ -82,7 +81,7 @@ private fun AgendaPagerOrLoading(
sessionFilters: List<SessionFilter>,
onSessionClick: (sessionId: String, roomId: String, startTimestamp: Long, endTimestamp: Long) -> Unit,
) {
ButtonRefreshableLceLayout(viewModel<AgendLayoutViewModel>()){
ButtonRefreshableLceLayout(viewModel<AgendaLayoutViewModel>()){
val days = agendaToDays(it)

AgendaPager(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ fun AgendaPager(
count = days.size,
state = pagerState,
) { page ->
val viewModel = viewModel<AgendLayoutViewModel>()
val viewModel = viewModel<AgendaLayoutViewModel>()
SwipeRefreshableLceLayout(viewModel = viewModel) {
val days = agendaToDays(it)
val items = days[page].roomSchedules.flatMap { it.scheduleSessions }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
package fr.androidmakers.store

import fr.androidmakers.store.model.*
import kotlinx.coroutines.flow.*
import fr.androidmakers.store.model.Agenda
import fr.androidmakers.store.model.Partner
import fr.androidmakers.store.model.Room
import fr.androidmakers.store.model.ScheduleSlot
import fr.androidmakers.store.model.Session
import fr.androidmakers.store.model.Speaker
import fr.androidmakers.store.model.Venue
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.combine

/**
*
Expand Down Expand Up @@ -39,11 +46,11 @@ interface AndroidMakersStore {
} else {
Result.success(
Agenda(
sessions.getOrThrow().associateBy { it.id },
slots.getOrThrow(),
rooms.getOrThrow().associateBy { it.id },
speakers.getOrThrow().associateBy { it.id }
)
sessions.getOrThrow().associateBy { it.id },
slots.getOrThrow(),
rooms.getOrThrow().associateBy { it.id },
speakers.getOrThrow().associateBy { it.id }
)
)
}
}
Expand Down

0 comments on commit 2f70064

Please sign in to comment.