@supabase/storage-js 3.0.0-next.11 → 3.0.0-next.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -794,7 +794,10 @@ var StorageFileApi = class extends BaseApiClient {
794
794
  * @category File Buckets
795
795
  * @param path The relative file path. Should be of the format `folder/subfolder/filename.png`. The bucket must already exist before attempting to update.
796
796
  * @param fileBody The body of the file to be stored in the bucket.
797
- * @param fileOptions Optional file upload options including cacheControl, contentType, upsert, and metadata.
797
+ * @param fileOptions Optional file upload options including cacheControl, contentType, and metadata.
798
+ * **Note:** The `upsert` option has no effect here. `update()` always replaces the
799
+ * file at the given path, so the `x-upsert` header is not sent. To control upsert
800
+ * behavior, use `upload()` instead.
798
801
  * @returns Promise with response containing file path, id, and fullPath or error
799
802
  *
800
803
  * @example Update file
@@ -804,8 +807,7 @@ var StorageFileApi = class extends BaseApiClient {
804
807
  * .storage
805
808
  * .from('avatars')
806
809
  * .update('public/avatar1.png', avatarFile, {
807
- * cacheControl: '3600',
808
- * upsert: true
810
+ * cacheControl: '3600'
809
811
  * })
810
812
  * ```
811
813
  *
@@ -836,6 +838,7 @@ var StorageFileApi = class extends BaseApiClient {
836
838
  * - RLS policy permissions required:
837
839
  * - `buckets` table permissions: none
838
840
  * - `objects` table permissions: `update` and `select`
841
+ * - `update()` always replaces the file at the given path regardless of the `upsert` option.
839
842
  * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
840
843
  * - For React Native, using either `Blob`, `File` or `FormData` does not work as intended. Update file using `ArrayBuffer` from base64 file data instead, see example below.
841
844
  */
@@ -1487,7 +1490,7 @@ var StorageFileApi = class extends BaseApiClient {
1487
1490
 
1488
1491
  //#endregion
1489
1492
  //#region src/lib/version.ts
1490
- const version = "3.0.0-next.11";
1493
+ const version = "3.0.0-next.13";
1491
1494
 
1492
1495
  //#endregion
1493
1496
  //#region src/lib/constants.ts