Validate matrix id on the front end. Fixes #245
authorDessalines <tyhou13@gmx.com>
Fri, 9 Apr 2021 04:20:34 +0000 (00:20 -0400)
committerDessalines <tyhou13@gmx.com>
Fri, 9 Apr 2021 04:20:34 +0000 (00:20 -0400)
src/shared/components/person.tsx

index 211b229c1216b5d081341a7b6beea79fd370c40f..57d78aa30c8b82685494f3b65c419fabb8f143b7 100644 (file)
@@ -750,7 +750,7 @@ export class Person extends Component<any, PersonState> {
                   this,
                   this.handleUserSettingsMatrixUserIdChange
                 )}
-                minLength={3}
+                pattern="^@[A-Za-z0-9._=-]+:[A-Za-z0-9.-]+\.[A-Za-z]{2,}$"
               />
             </div>
           </div>