Skip to content

UNEXPECTED BEHAVIOR 'move' method #1670

@flowtyone

Description

@flowtyone

Bug report

Describe the bug

When using the 'move' method in javascript storage SDK e.g:

await client.from('bucket_name').move("file_prev_name.ext", "file_new_name.ext");

The moved file's created_at timestamp changes to the current time.

To Reproduce

  1. Create a bucket on supabase
  2. Create a folder and upload a file to it.
  3. Make a request to list the folder using the 'list' method
  4. Observe the 'created_at' date of the uploaded file
  5. Use the javascript sdk as shown above to move the file to another folder.
  6. List the new folder contents, and observe the changed 'created_at' date

Expected behavior

'created_at' timestamp should remain identical to when the file was created, as it would on a normal file explorer.

Additional context

We've moved a large amount of files from one folder to another and this issue has severely impaired our service. We rely on the 'created_at' timestamp to sort files on our product and serve them in a chronological order.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstorage-jsRelated to the storage-js library.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions