mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-02-03 08:43:48 +03:00
Merge pull request #783 from hydralauncher/fix/replacing-underscore-with-whitespace
feat: replacing underscore with whitespace
This commit is contained in:
commit
64f4dad7cc
@ -51,9 +51,13 @@ export const removeSpecialEditionFromName = (name: string) =>
|
|||||||
export const removeDuplicateSpaces = (name: string) =>
|
export const removeDuplicateSpaces = (name: string) =>
|
||||||
name.replace(/\s{2,}/g, " ");
|
name.replace(/\s{2,}/g, " ");
|
||||||
|
|
||||||
|
export const replaceUnderscoreWithSpace = (name: string) =>
|
||||||
|
name.replace(/_/g, " ");
|
||||||
|
|
||||||
export const formatName = pipe<string>(
|
export const formatName = pipe<string>(
|
||||||
removeReleaseYearFromName,
|
removeReleaseYearFromName,
|
||||||
removeSpecialEditionFromName,
|
removeSpecialEditionFromName,
|
||||||
|
replaceUnderscoreWithSpace,
|
||||||
(str) => str.replace(/DIRECTOR'S CUT/g, ""),
|
(str) => str.replace(/DIRECTOR'S CUT/g, ""),
|
||||||
removeSymbolsFromName,
|
removeSymbolsFromName,
|
||||||
removeDuplicateSpaces,
|
removeDuplicateSpaces,
|
||||||
|
Loading…
Reference in New Issue
Block a user