fix filtering of quote uri
apparently filtering with `x => x !== null` will let `undefined` through…
This commit is contained in:
		
							parent
							
								
									26e0412fbb
								
							
						
					
					
						commit
						3a3098f932
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -483,7 +483,7 @@ export class ApNoteService {
 | 
				
			||||||
				}
 | 
									}
 | 
				
			||||||
			};
 | 
								};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
			const uris = unique([note._misskey_quote, note.quoteUrl, note.quoteUri].filter(x => x !== null));
 | 
								const uris = unique([note._misskey_quote, note.quoteUrl, note.quoteUri].filter(x => x != null));
 | 
				
			||||||
			const results = await Promise.all(uris.map(tryResolveNote));
 | 
								const results = await Promise.all(uris.map(tryResolveNote));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
			quote = results.filter((x): x is { status: 'ok', res: MiNote } => x.status === 'ok').map(x => x.res).at(0);
 | 
								quote = results.filter((x): x is { status: 'ok', res: MiNote } => x.status === 'ok').map(x => x.res).at(0);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue