Skip to content

Custom function to extend rejected files #576

@Spin1987

Description

@Spin1987

Thanks for your awesome file upload.
What about a custom function to extend the rejected file upload logic?

I can define "accept" to whitelist file extensions, thats pretty nice. But i cant add a check for files with 0 size. I can do it by my self, but then i have all the 'invalid' files in my files array not in my rejected files array.

 $scope.handleFileSelected = function ($files, $rejectedFiles) {
      if ($files && $files.length > 0) {
       // i would like to do this in a fn which add all files in the rejected files.
        var filesWithZeroSize = getFilesWithZeroSize($files);
       }
    }

Thank you very much :)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions