@Synchronized access to cache
This commit is contained in:
parent
5906c5f0fa
commit
c4ac42f738
1 changed files with 1 additions and 0 deletions
|
@ -51,6 +51,7 @@ class ProfileFunctionImplementation @Inject constructor(
|
|||
.toObservable(EventEffectiveProfileSwitchChanged::class.java)
|
||||
.observeOn(aapsSchedulers.io)
|
||||
.subscribe(
|
||||
@Synchronized
|
||||
{
|
||||
for (index in cache.size() - 1 downTo 0) {
|
||||
if (cache.keyAt(index) > it.startDate) {
|
||||
|
|
Loading…
Reference in a new issue