@ -86,6 +86,7 @@ abstract class AppDatabase : RoomDatabase() {
db.execSQL("update book_sources set loginUi = null where loginUi = 'null'")
db.execSQL("update rssSources set loginUi = null where loginUi = 'null'")
db.execSQL("update httpTTS set loginUi = null where loginUi = 'null'")
db.execSQL("update httpTTS set concurrentRate = '0' where loginUi is null")
}
@ -18,7 +18,7 @@ data class HttpTTS(
var name: String = "",
var url: String = "",
var contentType: String? = null,
override var concurrentRate: String? = null,
override var concurrentRate: String? = "0",
override var loginUrl: String? = null,
override var loginUi: String? = null,
override var header: String? = null,
@ -285,9 +285,10 @@ class AnalyzeUrl(
if (concurrentRate.isNullOrEmpty()) {
return
val fetchRecord = accessTime[source.getKey()]
var fetchRecord = accessTime[source.getKey()]
if (fetchRecord == null) {
accessTime[source.getKey()] = FetchRecord(System.currentTimeMillis(), 1)
fetchRecord = FetchRecord(System.currentTimeMillis(), 1)
accessTime[source.getKey()] = fetchRecord
val waitTime = synchronized(fetchRecord) {