Skip to content

[storage] overwriting the same file #6

Closed
@archelogos

Description

@archelogos

Hi there!!

Currently it's not possible to upload more than 1 file which is overwritten every time that another file is uploaded.
It occurs because the ref path is a constant string 'images'.

In /storage/index.html line 88:

var uploadTask = storageRef.child('images').put(file, metadata);

So something like this should fix this problem:

var uploadTask = storageRef.child('images/' + new Date().getTime() + file.name).put(file, metadata);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions