add download file size in MB and error code

This commit is contained in:
Pritimay Sarkar
2023-10-02 21:06:22 +05:30
parent 211429fb8f
commit 744735d7ba

View File

@@ -68,7 +68,7 @@ class DashboardActivity : AppCompatActivity() {
.addOnProgressListener { updateProgress -> .addOnProgressListener { updateProgress ->
Toast.makeText( Toast.makeText(
this, this,
"FirebaseAppDistribution progress: ${updateProgress.updateStatus}. ${updateProgress.apkBytesDownloaded}/${updateProgress.apkFileTotalBytes}", "${updateProgress.updateStatus}. ${updateProgress.apkBytesDownloaded / 1048576} /${updateProgress.apkFileTotalBytes / 1048576} MB",
Toast.LENGTH_SHORT Toast.LENGTH_SHORT
).show() ).show()
} }
@@ -82,6 +82,7 @@ class DashboardActivity : AppCompatActivity() {
else -> { else -> {
// Handle other errors. // Handle other errors.
Toast.makeText(this, "AppDistribution error, status: ${e.errorCode}", Toast.LENGTH_SHORT).show()
} }
} }
FirebaseCrashlytics.getInstance().recordException(e) FirebaseCrashlytics.getInstance().recordException(e)