make hardcoded "cadence.moe" configurable
This commit is contained in:
		
							parent
							
								
									92cd628a6c
								
							
						
					
					
						commit
						458a620f4a
					
				
					 5 changed files with 10 additions and 7 deletions
				
			
		| 
						 | 
				
			
			@ -11,6 +11,7 @@ function eventSenderIsFromDiscord(sender) {
 | 
			
		|||
	// If it's from a user in the bridge's namespace, then it originated from discord
 | 
			
		||||
	// This includes messages sent by the appservice's bot user, because that is what's used for webhooks
 | 
			
		||||
	// TODO: It would be nice if bridge system messages wouldn't trigger this check and could be bridged from matrix to discord, while webhook reflections would remain ignored...
 | 
			
		||||
	// TODO that only applies to the above todo: But you'd have to watch out for the /icon command, where the bridge bot would set the room avatar, and that shouldn't be reflected into the room a second time.
 | 
			
		||||
	if (userRegex.some(x => sender.match(x))) {
 | 
			
		||||
		return true
 | 
			
		||||
	}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue