allow handles to start with a number (#1231)
* allow handles to start with a number * don't allow leading hyphen
This commit is contained in:
		
							parent
							
								
									257c15ec1f
								
							
						
					
					
						commit
						4cc2695d84
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		|  | @ -3,7 +3,7 @@ export function makeValidHandle(str: string): string { | |||
|     str = str.slice(0, 20) | ||||
|   } | ||||
|   str = str.toLowerCase() | ||||
|   return str.replace(/^[^a-z]+/g, '').replace(/[^a-z0-9-]/g, '') | ||||
|   return str.replace(/^[^a-z0-9]+/g, '').replace(/[^a-z0-9-]/g, '') | ||||
| } | ||||
| 
 | ||||
| export function createFullHandle(name: string, domain: string): string { | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue