feat: 修复检验有效书源移除失效分组失败的bug

pull/248/head
gedoor 4 years ago
parent 4271579418
commit e7ecca5c0d
  1. 4
      app/src/main/java/io/legado/app/data/entities/BookSource.kt

@ -96,7 +96,7 @@ data class BookSource(
fun addGroup(group: String) {
bookSourceGroup?.let {
if (!it.contains(group)) {
bookSourceGroup = "$it;$group"
bookSourceGroup = "$it,$group"
}
} ?: let {
bookSourceGroup = group
@ -104,7 +104,7 @@ data class BookSource(
}
fun removeGroup(group: String) {
bookSourceGroup?.splitNotBlank(",")?.toHashSet()?.let {
bookSourceGroup?.splitNotBlank("[,;]".toRegex())?.toHashSet()?.let {
it.remove(group)
bookSourceGroup = TextUtils.join(",", it)
}

Loading…
Cancel
Save