Skip to content

Commit 7e1dfaa

Browse files
committed
chore: Add callout for Android storage permissions
1 parent 6b3d93a commit 7e1dfaa

File tree

1 file changed

+8
-0
lines changed
  • src/pages/[platform]/build-a-backend/storage/download-files

1 file changed

+8
-0
lines changed

src/pages/[platform]/build-a-backend/storage/download-files/index.mdx

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,14 @@ const { body, eTag } = await downloadData({
336336

337337
Use the `downloadFile` API to download the file locally on the client.
338338

339+
<Callout>
340+
**Note:** When downloading a file that will overwrite prexisting file, ensure that your app has the proper write permission to overwrite it. In particular, if your app uses scoped storage, your app must must request that the user grant your app write access to that particular file [as described here](https://developer.android.com/training/data-storage/shared/media#update-other-apps-files) if a different app contributed that file to the media store.
341+
342+
To learn more, refer to Android's developer documentation about [Scoped Storage](https://developer.android.com/training/data-storage#scoped-storage).
343+
344+
Amplify will throw a `StorageException` if it is unable to modify a preexisting file.
345+
</Callout>
346+
339347
<BlockSwitcher>
340348
<Block name="Java">
341349

0 commit comments

Comments
 (0)