Add recommendations to SuperStream

This commit is contained in:
Blatzar 2022-10-07 18:57:22 +02:00
parent 0f60c2a65d
commit 865fcf8dc1
2 changed files with 4 additions and 3 deletions

View File

@ -1,5 +1,5 @@
// use an integer for version numbers // use an integer for version numbers
version = 3 version = 4
cloudstream { cloudstream {
@ -7,7 +7,7 @@ cloudstream {
// All of these properties are optional, you can safely remove them // All of these properties are optional, you can safely remove them
// description = "Lorem Ipsum" // description = "Lorem Ipsum"
// authors = listOf("Cloudburst") authors = listOf("Blatzar")
/** /**
* Status int as the following: * Status int as the following:

View File

@ -257,6 +257,7 @@ class SuperStream : MainAPI() {
private data class Data( private data class Data(
@JsonProperty("id") val id: Int? = null, @JsonProperty("id") val id: Int? = null,
@JsonProperty("mid") val mid: Int? = null,
@JsonProperty("box_type") val boxType: Int? = null, @JsonProperty("box_type") val boxType: Int? = null,
@JsonProperty("title") val title: String? = null, @JsonProperty("title") val title: String? = null,
@JsonProperty("poster_org") val posterOrg: String? = null, @JsonProperty("poster_org") val posterOrg: String? = null,
@ -269,7 +270,7 @@ class SuperStream : MainAPI() {
fun toSearchResponse(api: MainAPI): MovieSearchResponse? { fun toSearchResponse(api: MainAPI): MovieSearchResponse? {
return api.newMovieSearchResponse( return api.newMovieSearchResponse(
this.title ?: "", this.title ?: "",
LoadData(this.id ?: return null, this.boxType).toJson(), LoadData(this.id ?: this.mid ?: return null, this.boxType ?: ResponseTypes.Movies.value).toJson(),
ResponseTypes.getResponseType(this.boxType).toTvType(), ResponseTypes.getResponseType(this.boxType).toTvType(),
false false
) { ) {