mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	streams: Refactor multi-option helpers into separate functions.
For internal stream messages, most of the time, we have access to a Stream object. For the few corner cases where we don't, it is a much cleaner approach to have a separate function that accepts a stream name than having one multi-option helper that accepts both names and objects.
This commit is contained in:
		@@ -78,9 +78,8 @@ From image editing program:
 | 
			
		||||
        ]  # type: List[Dict[str, Any]]
 | 
			
		||||
 | 
			
		||||
        messages = [internal_prep_stream_message(
 | 
			
		||||
            realm, message['sender'],
 | 
			
		||||
            'message formatting', message['content'],
 | 
			
		||||
            stream=stream
 | 
			
		||||
            realm, message['sender'], stream,
 | 
			
		||||
            'message formatting', message['content']
 | 
			
		||||
        ) for message in staged_messages]
 | 
			
		||||
 | 
			
		||||
        message_ids = do_send_messages(messages)
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user