Implement simple stats screen (#8068)

* Implement simple stats screen

* Review Changes

* Some other changes

* Remove unused

* Small changes

* Review Changes 2 + Cleanup

* Review Changes 3

* Cleanup leftovers

* Optimize imports
This commit is contained in:
AntsyLich
2022-11-27 02:50:26 +06:00
committed by GitHub
parent e14909fff4
commit 3d7591feca
26 changed files with 695 additions and 14 deletions
@@ -0,0 +1,12 @@
package eu.kanade.domain.history.interactor
import eu.kanade.domain.history.repository.HistoryRepository
class GetTotalReadDuration(
private val repository: HistoryRepository,
) {
suspend fun await(): Long {
return repository.getTotalReadDuration()
}
}
@@ -10,6 +10,8 @@ interface HistoryRepository {
suspend fun getLastHistory(): HistoryWithRelations?
suspend fun getTotalReadDuration(): Long
suspend fun resetHistory(historyId: Long)
suspend fun resetHistoryByMangaId(mangaId: Long)