Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit aa8cd9ee authored by Abhishek Aggarwal's avatar Abhishek Aggarwal
Browse files

App Lounge: Remove app from database once we are installed

parent 6f16f5b4
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -65,7 +65,10 @@ class FusedManagerImpl @Inject constructor(
        } else {
            Log.d(TAG, "Unable to update download status!")
        }
        if (status == Status.INSTALLED) flushOldDownload(fusedDownload.package_name)
        if (status == Status.INSTALLED) {
            flushOldDownload(fusedDownload.package_name)
            databaseRepository.deleteDownload(fusedDownload)
        }
    }

    suspend fun downloadApp(fusedDownload: FusedDownload) {
+2 −0
Original line number Diff line number Diff line
@@ -84,5 +84,7 @@ class PWAManagerModule @Inject constructor(
        // Update status
        fusedDownload.status = Status.INSTALLED
        databaseRepository.updateDownload(fusedDownload)

        databaseRepository.deleteDownload(fusedDownload)
    }
}