Skip to content

Commit

Permalink
Update packages/@uppy/utils/src/getAllowedMetaFields.ts
Browse files Browse the repository at this point in the history
Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
  • Loading branch information
Murderlon and aduh95 authored Mar 25, 2024
1 parent 44ff7f9 commit 5de0615
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/@uppy/utils/src/getAllowedMetaFields.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ export default function getAllowedMetaFields<M extends Meta>(
fields: string[] | boolean,
meta: M,
): string[] {
if (Array.isArray(fields)) {
return fields
}
if (fields === true) {
return Object.keys(meta)
}
if (Array.isArray(fields)) {
return fields
}
return []
}

0 comments on commit 5de0615

Please sign in to comment.