corrupted schedule bugfix
This commit is contained in:
parent
eda34bce65
commit
2f6f3a3066
|
@ -10,8 +10,8 @@ android {
|
||||||
applicationId "com.adlerosn.brasilfurfest"
|
applicationId "com.adlerosn.brasilfurfest"
|
||||||
minSdkVersion 21
|
minSdkVersion 21
|
||||||
targetSdkVersion 29
|
targetSdkVersion 29
|
||||||
versionCode 49
|
versionCode 50
|
||||||
versionName "2019.8.6.3"
|
versionName "2019.8.8.0"
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,12 +35,11 @@ open class Observable<T : Any?> {
|
||||||
open fun hasChanged() = changed
|
open fun hasChanged() = changed
|
||||||
fun notifyObservers() = notifyObservers(null)
|
fun notifyObservers() = notifyObservers(null)
|
||||||
fun notifyObservers(arg: T?) {
|
fun notifyObservers(arg: T?) {
|
||||||
doAsync {
|
// Don't do anything async here or you might lose data
|
||||||
if (hasChanged()) {
|
if (hasChanged()) {
|
||||||
clearChanged()
|
clearChanged()
|
||||||
observers.forEach {
|
observers.forEach {
|
||||||
it.update(this, arg)
|
it.update(this, arg)
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user