Skip to content

Commit f327253

Browse files
Copilotalexr00
andauthored
Revert prsTreeModel.ts cache invalidation approach
Agent-Logs-Url: https://github.com/microsoft/vscode-pull-request-github/sessions/001ddef0-6d36-4dcc-96f7-ed3f3d2901e5 Co-authored-by: alexr00 <38270282+alexr00@users.noreply.github.com>
1 parent a84a532 commit f327253

File tree

1 file changed

+1
-12
lines changed

1 file changed

+1
-12
lines changed

src/view/prsTreeModel.ts

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,18 +87,7 @@ export class PrsTreeModel extends Disposable {
8787
if (e.new) {
8888
prs.push({ model: e.new, event: {} });
8989
}
90-
91-
// When a new active PR is discovered (e.g. PR created on GitHub website),
92-
// check if it's already in the local PR cache. If not, clear the local cache
93-
// and fire a full folder refresh so the "Local Pull Request Branches" category
94-
// picks up the newly-associated branch.
95-
if (e.new && !this._allCachedPRs.has(e.new)) {
96-
const cache = this.getFolderCache(manager);
97-
cache.delete(PRType.LocalPullRequest);
98-
this._onDidChangeData.fire(manager);
99-
} else {
100-
this._onDidChangeData.fire(prs);
101-
}
90+
this._onDidChangeData.fire(prs);
10291

10392
if (this._activePRDisposables.has(manager)) {
10493
disposeAll(this._activePRDisposables.get(manager)!);

0 commit comments

Comments
 (0)