Remove dead code (#9035)

This commit is contained in:
Šimon Brandner 2022-07-11 07:52:44 +02:00 committed by GitHub
parent d1928d2cb3
commit 19e514d83c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
28 changed files with 6 additions and 412 deletions

View file

@ -24,24 +24,6 @@ export enum AddressType {
MatrixRoomId = "mx-room-id",
}
export const addressTypes = [AddressType.Email, AddressType.MatrixRoomId, AddressType.MatrixUserId];
// PropType definition for an object describing
// an address that can be invited to a room (which
// could be a third party identifier or a matrix ID)
// along with some additional information about the
// address / target.
export interface IUserAddress {
addressType: AddressType;
address: string;
displayName?: string;
avatarMxc?: string;
// true if the address is known to be a valid address (eg. is a real
// user we've seen) or false otherwise (eg. is just an address the
// user has entered)
isKnown?: boolean;
}
export function getAddressType(inputText: string): AddressType | null {
if (emailRegex.test(inputText)) {
return AddressType.Email;