mirror of
https://github.com/mihonapp/mihon.git
synced 2025-10-16 08:09:42 +02:00
Fix Bangumi search including novels (#1885)
This commit is contained in:
@@ -11,6 +11,8 @@ The format is a modified version of [Keep a Changelog](https://keepachangelog.co
|
||||
- `Other` - for technical stuff.
|
||||
|
||||
## [Unreleased]
|
||||
### Fixes
|
||||
- Fix Bangumi search results including novels ([@MajorTanya](https://github.com/MajorTanya)) ([#1885](https://github.com/mihonapp/mihon/pull/1885))
|
||||
|
||||
## [v0.18.0] - 2025-03-20
|
||||
### Added
|
||||
|
@@ -104,6 +104,7 @@ class BangumiApi(
|
||||
.awaitSuccess()
|
||||
.parseAs<BGMSearchResult>()
|
||||
.data
|
||||
.filter { it.platform == null || it.platform == "漫画" }
|
||||
.map { it.toTrackSearch(trackId) }
|
||||
}
|
||||
}
|
||||
|
@@ -25,6 +25,7 @@ data class BGMSubject(
|
||||
val volumes: Long = 0,
|
||||
val eps: Long = 0,
|
||||
val rating: BGMSubjectRating?,
|
||||
val platform: String?,
|
||||
) {
|
||||
fun toTrackSearch(trackId: Long): TrackSearch = TrackSearch.create(trackId).apply {
|
||||
remote_id = this@BGMSubject.id
|
||||
|
Reference in New Issue
Block a user