Set source id when inserting to db ()

This commit is contained in:
Ivan Iskandar 2022-10-28 09:34:21 +07:00 committed by GitHub
parent 1704dc062d
commit 187e9f94aa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,7 +11,7 @@ class NetworkToLocalManga(
val localManga = getManga(manga.url, sourceId)
return when {
localManga == null -> {
val id = insertManga(manga)
val id = insertManga(manga.copy(source = sourceId))
manga.copy(id = id!!)
}
!localManga.favorite -> {