Fix retrying failed m->d edits
The mutated event was being used as the error payload instead of the original event, so it forgot that it was an edit.
This commit is contained in:
		
							parent
							
								
									960eca3b39
								
							
						
					
					
						commit
						3975550582
					
				
					 2 changed files with 2 additions and 2 deletions
				
			
		|  | @ -93,7 +93,7 @@ Total transitive production dependencies: 137 | |||
| 
 | ||||
| ### <font size="+2">🦕</font> | ||||
| 
 | ||||
| * (31) better-sqlite3: SQLite3 is the best database, and this is the best library for it. | ||||
| * (31) better-sqlite3: SQLite is the best database, and this is the best library for it. | ||||
| * (27) @cloudrac3r/pug: Language for dynamic web pages. This is my fork. (I released code that hadn't made it to npm, and removed the heavy pug-filters feature.) | ||||
| * (16) stream-mime-type@1: This seems like the best option. Version 1 is used because version 2 is ESM-only. | ||||
| * (9) h3: Web server. OOYE needs this for the appservice listener, authmedia proxy, self-service, and more. | ||||
|  |  | |||
|  | @ -546,7 +546,7 @@ async function eventToMessage(event, guild, di) { | |||
| 			if (!messageIDsToEdit.length) return | ||||
| 
 | ||||
| 			// Ok, it's an edit.
 | ||||
| 			event.content = event.content["m.new_content"] | ||||
| 			event = {...event, content: event.content["m.new_content"]} | ||||
| 
 | ||||
| 			// Is it editing a reply? We need special handling if it is.
 | ||||
| 			// Get the original event, then check if it was a reply
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue