File tree Expand file tree Collapse file tree
apps/desktop/src/main/browser-agent Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2013,12 +2013,14 @@ export function reloadPage(contents: WebContents): void {
20132013}
20142014
20152015/**
2016- * Reloads past the HTTP cache, the browser's Shift-reload. A hung page takes
2017- * the plain reload's recovery instead: its renderer must be restarted, since
2018- * reloading it in place waits on the hung page.
2016+ * Reloads past the HTTP cache, the browser's Shift-reload. A failed or hung
2017+ * page takes the plain reload's recovery instead: a load error retries the
2018+ * URL that failed, which need not be the committed page, and a hung renderer
2019+ * must be restarted, since reloading it in place waits on the hung page.
20192020 */
20202021function hardReloadPage ( contents : WebContents ) : void {
2021- if ( tabForContents ( contents ) ?. pageIssue ?. kind === 'unresponsive' ) {
2022+ const issue = tabForContents ( contents ) ?. pageIssue
2023+ if ( issue ?. kind === 'load-error' || issue ?. kind === 'unresponsive' ) {
20222024 reloadPage ( contents )
20232025 return
20242026 }
You can’t perform that action at this time.
0 commit comments