Skip to content

Commit

Permalink
:fix rooms view model perPage
Browse files Browse the repository at this point in the history
  • Loading branch information
m1a2st committed Aug 17, 2023
1 parent 87ad512 commit bd6db8a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ class GetRoomsPresenter : GetRoomsUseCase.GetRoomsPresenter {
)
}


private fun Room.toRoomsViewModel(): GetRoomsViewModel.RoomViewModel =
GetRoomsViewModel.RoomViewModel(
id = roomId!!.value,
Expand All @@ -43,6 +42,6 @@ private fun Room.Player.toGetRoomsView(): GetRoomsViewModel.RoomViewModel.Player
private fun Pagination<Room>.toPage(size: Int): GetRoomsViewModel.Page =
GetRoomsViewModel.Page(
page = page,
offset = offset,
perPage = offset,
total = size
)
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,6 @@ data class GetRoomsViewModel(
data class Page(
val total: Int,
val page: Int,
val offset: Int
val perPage: Int
)
}

0 comments on commit bd6db8a

Please sign in to comment.