From 4e0efb4e4571c0273f3acd427d6c29e755f7e8d2 Mon Sep 17 00:00:00 2001 From: kunfei Date: Mon, 19 Aug 2019 10:17:21 +0800 Subject: [PATCH] up --- .../java/io/legado/app/data/entities/SearchBook.kt | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/app/src/main/java/io/legado/app/data/entities/SearchBook.kt b/app/src/main/java/io/legado/app/data/entities/SearchBook.kt index 40b0b6317..f679ff10e 100644 --- a/app/src/main/java/io/legado/app/data/entities/SearchBook.kt +++ b/app/src/main/java/io/legado/app/data/entities/SearchBook.kt @@ -32,6 +32,19 @@ data class SearchBook( var originOrder: Int = 0 ) : Parcelable, BaseBook { + override fun equals(other: Any?): Boolean { + if (other is SearchBook) { + if (other.bookUrl == bookUrl) { + return true + } + } + return false + } + + override fun hashCode(): Int { + return bookUrl.hashCode() + } + @IgnoredOnParcel @Ignore override var variableMap: HashMap? = null