Loading app/src/main/java/foundation/e/apps/data/updates/UpdatesManagerImpl.kt +17 −2 Original line number Diff line number Diff line Loading @@ -128,7 +128,11 @@ class UpdatesManagerImpl @Inject constructor( } val nonFaultyUpdateList = faultyAppRepository.removeFaultyApps(updateList) return Pair(nonFaultyUpdateList, status) val systemApps = getSystemUpdates(false).toMutableList() putAppLoungeAtLast(systemApps) return Pair(nonFaultyUpdateList + systemApps, status) } suspend fun getUpdatesOSS(): Pair<List<Application>, ResultStatus> { Loading Loading @@ -162,7 +166,11 @@ class UpdatesManagerImpl @Inject constructor( } val nonFaultyUpdateList = faultyAppRepository.removeFaultyApps(updateList) return Pair(nonFaultyUpdateList, status) val systemApps = getSystemUpdates(false).toMutableList() putAppLoungeAtLast(systemApps) return Pair(nonFaultyUpdateList + systemApps, status) } suspend fun getSystemUpdates(onlySelf: Boolean = false): List<Application> { Loading Loading @@ -193,6 +201,13 @@ class UpdatesManagerImpl @Inject constructor( return updateList } private fun putAppLoungeAtLast(updateList: MutableList<Application>) { val appLoungeItem = updateList.find { it.isSystemApp && it.package_name == context.packageName } ?: return updateList.remove(appLoungeItem) updateList.add(appLoungeItem) } private fun getSdkLevel(): Int { return Build.VERSION.SDK_INT } Loading Loading
app/src/main/java/foundation/e/apps/data/updates/UpdatesManagerImpl.kt +17 −2 Original line number Diff line number Diff line Loading @@ -128,7 +128,11 @@ class UpdatesManagerImpl @Inject constructor( } val nonFaultyUpdateList = faultyAppRepository.removeFaultyApps(updateList) return Pair(nonFaultyUpdateList, status) val systemApps = getSystemUpdates(false).toMutableList() putAppLoungeAtLast(systemApps) return Pair(nonFaultyUpdateList + systemApps, status) } suspend fun getUpdatesOSS(): Pair<List<Application>, ResultStatus> { Loading Loading @@ -162,7 +166,11 @@ class UpdatesManagerImpl @Inject constructor( } val nonFaultyUpdateList = faultyAppRepository.removeFaultyApps(updateList) return Pair(nonFaultyUpdateList, status) val systemApps = getSystemUpdates(false).toMutableList() putAppLoungeAtLast(systemApps) return Pair(nonFaultyUpdateList + systemApps, status) } suspend fun getSystemUpdates(onlySelf: Boolean = false): List<Application> { Loading Loading @@ -193,6 +201,13 @@ class UpdatesManagerImpl @Inject constructor( return updateList } private fun putAppLoungeAtLast(updateList: MutableList<Application>) { val appLoungeItem = updateList.find { it.isSystemApp && it.package_name == context.packageName } ?: return updateList.remove(appLoungeItem) updateList.add(appLoungeItem) } private fun getSdkLevel(): Int { return Build.VERSION.SDK_INT } Loading