pull/1606/head
kunfei 3 years ago
parent ebc95861a6
commit 2d147c3e47
  1. 17
      app/src/main/java/io/legado/app/help/ContentProcessor.kt

@ -46,15 +46,14 @@ class ContentProcessor private constructor(
@Synchronized @Synchronized
fun upReplaceRules() { fun upReplaceRules() {
titleReplaceRules.clear() titleReplaceRules.run {
contentReplaceRules.clear() clear()
titleReplaceRules.addAll(appDb.replaceRuleDao.findEnabledByTitleScope(bookName, bookOrigin)) addAll(appDb.replaceRuleDao.findEnabledByTitleScope(bookName, bookOrigin))
contentReplaceRules.addAll( }
appDb.replaceRuleDao.findEnabledByContentScope( contentReplaceRules.run {
bookName, clear()
bookOrigin addAll(appDb.replaceRuleDao.findEnabledByContentScope(bookName, bookOrigin))
) }
)
} }
@Synchronized @Synchronized

Loading…
Cancel
Save