Removes all invalid characters from a given file name.
This function takes a file name string and an array of invalid characters
specific to file names, then removes all occurrences of these invalid characters
from the file name string.
Parameters
filename: string
The file name string from which invalid characters will be removed.
Returns string
A new string with all invalid file name characters removed.
Removes all invalid characters from a given file name.
This function takes a file name string and an array of invalid characters specific to file names, then removes all occurrences of these invalid characters from the file name string.