fix: preserve probe errors and complete refresh alerts

This commit is contained in:
Thomas Durieux committed 2026-10-09 06:17:40 +00:00
1 parent 2b20abe0a5
commit 9a2707d4b8
6 files changed
+102 -11

No files matched your search

+8 -3
View File
@@ -628,6 +628,14 @@ export default class Repository {
/** Update the repository if a new commit exists. */
async updateIfNeeded(opt?: { force: boolean }): Promise<void> {
try { await this.refreshIfNeeded(opt); }
catch (error) {
void notifyOwnerAccessProblem(this.owner.id, error);
throw error;
}
}
private async refreshIfNeeded(opt?: { force: boolean }): Promise<void> {
this.assertNotArchived();
if (
this._model.options.expirationMode !== "never" &&
@@ -658,9 +666,6 @@ export default class Repository {
repo: this.source.data.repoName,
repositoryID: this.model.source.repositoryId,
force: true,
}).catch(error => {
void notifyOwnerAccessProblem(this.owner.id, error);
throw error;
});
// update the repository name if it has changed. Persist it