Update linter

This commit is contained in:
arkon
2022-05-10 17:54:52 -04:00
parent 8bee5accb7
commit ae7df4fb7f
49 changed files with 119 additions and 117 deletions

View File

@@ -42,7 +42,7 @@ class MigrationMangaController : ComposeController<MigrationMangaPresenter> {
},
onClickCover = {
router.pushController(MangaController(it.id))
}
},
)
}

View File

@@ -15,7 +15,7 @@ import uy.kohesive.injekt.api.get
class MigrationMangaPresenter(
private val sourceId: Long,
private val getFavoritesBySourceId: GetFavoritesBySourceId = Injekt.get()
private val getFavoritesBySourceId: GetFavoritesBySourceId = Injekt.get(),
) : BasePresenter<MigrationMangaController>() {
private val _state: MutableStateFlow<MigrateMangaState> = MutableStateFlow(MigrateMangaState.Loading)

View File

@@ -28,7 +28,7 @@ class SearchController(
constructor(mangaId: Long) : this(
Injekt.get<DatabaseHelper>()
.getManga(mangaId)
.executeAsBlocking()
.executeAsBlocking(),
)
private var newManga: Manga? = null

View File

@@ -30,8 +30,8 @@ class MigrationSourcesController : ComposeController<MigrationSourcesPresenter>(
parentController!!.router.pushController(
MigrationMangaController(
source.id,
source.name
)
source.name,
),
)
},
onLongClickItem = { source ->
@@ -51,12 +51,14 @@ class MigrationSourcesController : ComposeController<MigrationSourcesPresenter>(
true
}
R.id.asc_alphabetical,
R.id.desc_alphabetical -> {
R.id.desc_alphabetical,
-> {
presenter.setAlphabeticalSorting(itemId == R.id.asc_alphabetical)
true
}
R.id.asc_count,
R.id.desc_count -> {
R.id.desc_count,
-> {
presenter.setTotalSorting(itemId == R.id.asc_count)
true
}

View File

@@ -16,7 +16,7 @@ import uy.kohesive.injekt.api.get
class MigrationSourcesPresenter(
private val getSourcesWithFavoriteCount: GetSourcesWithFavoriteCount = Injekt.get(),
private val setMigrateSorting: SetMigrateSorting = Injekt.get()
private val setMigrateSorting: SetMigrateSorting = Injekt.get(),
) : BasePresenter<MigrationSourcesController>() {
private val _state: MutableStateFlow<MigrateSourceState> = MutableStateFlow(MigrateSourceState.Loading)

View File

@@ -20,7 +20,7 @@ class SourceFilterPresenter(
private val getLanguagesWithSources: GetLanguagesWithSources = Injekt.get(),
private val toggleSource: ToggleSource = Injekt.get(),
private val toggleLanguage: ToggleLanguage = Injekt.get(),
private val preferences: PreferencesHelper = Injekt.get()
private val preferences: PreferencesHelper = Injekt.get(),
) : BasePresenter<SourceFilterController>() {
private val _state: MutableStateFlow<SourceFilterState> = MutableStateFlow(SourceFilterState.Loading)
@@ -49,7 +49,7 @@ class SourceFilterPresenter(
header + it.value.map { source ->
FilterUiModel.Item(
source,
source.id.toString() !in preferences.disabledSources().get()
source.id.toString() !in preferences.disabledSources().get(),
)
}
}

View File

@@ -25,7 +25,7 @@ import java.util.TreeMap
class SourcePresenter(
private val getEnabledSources: GetEnabledSources = Injekt.get(),
private val toggleSource: ToggleSource = Injekt.get(),
private val toggleSourcePin: ToggleSourcePin = Injekt.get()
private val toggleSourcePin: ToggleSourcePin = Injekt.get(),
) : BasePresenter<SourceController>() {
private val _state: MutableStateFlow<SourceState> = MutableStateFlow(SourceState.Loading)