Skip to content

Commit b672726

Browse files
committed
Clear download link when new upload starts.
Bug: 32002078
1 parent be57336 commit b672726

File tree

1 file changed

+4
-0
lines changed
  • storage/app/src/main/java/com/google/firebase/quickstart/firebasestorage

1 file changed

+4
-0
lines changed

storage/app/src/main/java/com/google/firebase/quickstart/firebasestorage/MainActivity.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,10 @@ private void uploadFromUri(Uri fileUri) {
188188
// Save the File URI
189189
mFileUri = fileUri;
190190

191+
// Clear the last download, if any
192+
updateUI(mAuth.getCurrentUser());
193+
mDownloadUrl = null;
194+
191195
// Toast message in case the user does not see the notificatio
192196
Toast.makeText(this, "Uploading...", Toast.LENGTH_SHORT).show();
193197

0 commit comments

Comments
 (0)