Update fnTools.ts
This commit is contained in:
parent
d04f498c99
commit
a732cc04fd
@ -163,7 +163,7 @@ export function getRandom(min, max, decimals=0) {
|
|||||||
* @param {Array<File>} list - List of files.
|
* @param {Array<File>} list - List of files.
|
||||||
* @return number
|
* @return number
|
||||||
*/
|
*/
|
||||||
function getIndexOfFileList(name: string, list: Array<File>): number {
|
export function getIndexOfFileList(name: string, list: Array<File>): number {
|
||||||
return list.reduce(
|
return list.reduce(
|
||||||
(position, file, index) => (file.name === name ? index : position),
|
(position, file, index) => (file.name === name ? index : position),
|
||||||
-1
|
-1
|
||||||
|
Loading…
Reference in New Issue
Block a user