Various small fixes

This commit is contained in:
Paul Frazee 2022-12-30 15:32:07 -06:00
parent 3d91cf3137
commit 5eddbcea16
6 changed files with 9 additions and 7 deletions

View file

@ -185,8 +185,8 @@ export function makeValidHandle(str: string): string {
}
export function createFullHandle(name: string, domain: string): string {
name = name.replace(/[\.]+$/, '')
domain = domain.replace(/^[\.]+/, '')
name = (name || '').replace(/[\.]+$/, '')
domain = (domain || '').replace(/^[\.]+/, '')
return `${name}.${domain}`
}