This commit is contained in:
Mel O'Hagan 2023-01-10 17:00:18 +00:00
parent 7639c70dcb
commit f28d887ec4
1 changed files with 7 additions and 9 deletions

View File

@ -117,15 +117,13 @@
) )
} }
function cleanUrl(inputUrl) { const cleanUrl = inputUrl =>
return (
url url
?.replace(/(http)|(https)|[{}:]/g, "") ?.replace(/(http)|(https)|[{}:]/g, "")
?.replaceAll(".", "_") ?.replaceAll(".", "_")
?.replaceAll("/", " ") ?.replaceAll("/", " ")
?.trim() || inputUrl ?.trim() || inputUrl
)
}
function checkQueryName(inputUrl = null) { function checkQueryName(inputUrl = null) {
if (query && (!query.name || query.flags.urlName)) { if (query && (!query.name || query.flags.urlName)) {
query.flags.urlName = true query.flags.urlName = true