Skip to content

Commit e8e71ae

Browse files
authored
Fix PR webview restore (#8500)
1 parent e10792e commit e8e71ae

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/github/issueOverview.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,9 @@ export class IssueOverviewPanel<TItem extends IssueModel = IssueModel> extends W
354354
const isNewItem = !this._item || (this._item.number !== identity.number);
355355
if (isNewItem || !this._panel.webview.html) {
356356
this._panel.webview.html = this.getHtmlForWebview();
357-
this._postMessage({ command: 'pr.clear' });
357+
if (this._item) {
358+
this._postMessage({ command: 'pr.clear' });
359+
}
358360
}
359361

360362
// If no model provided, resolve it from the identity

0 commit comments

Comments
 (0)