Fix markdown images having duplicate ids (#157177)

Fixes #153144
This commit is contained in:
Matt Bierner
2022-08-04 21:31:42 -07:00
committed by GitHub
parent 5589b81019
commit b012216211
5 changed files with 20 additions and 42 deletions

View File

@@ -38,7 +38,7 @@ const previewStrings = {
export interface MarkdownContentProviderOutput {
html: string;
containingImages: { src: string }[];
containingImages: Set<string>;
}
@@ -88,7 +88,7 @@ export class MdDocumentRenderer {
const body = await this.renderBody(markdownDocument, resourceProvider);
if (token.isCancellationRequested) {
return { html: '', containingImages: [] };
return { html: '', containingImages: new Set() };
}
const html = `<!DOCTYPE html>