Merge pull request #4096 from matrix-org/bwindels/canonicalpill
Accept canonical alias for pillspull/21833/head
						commit
						744826db48
					
				| 
						 | 
				
			
			@ -128,7 +128,8 @@ const Pill = createReactClass({
 | 
			
		|||
            case Pill.TYPE_ROOM_MENTION: {
 | 
			
		||||
                const localRoom = resourceId[0] === '#' ?
 | 
			
		||||
                    MatrixClientPeg.get().getRooms().find((r) => {
 | 
			
		||||
                        return r.getAliases().includes(resourceId);
 | 
			
		||||
                        return r.getCanonicalAlias() === resourceId ||
 | 
			
		||||
                               r.getAliases().includes(resourceId);
 | 
			
		||||
                    }) : MatrixClientPeg.get().getRoom(resourceId);
 | 
			
		||||
                room = localRoom;
 | 
			
		||||
                if (!localRoom) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue