Skip to content

Commit 11cbbd1

Browse files
committed
registerAbort: Don't infinite-retry if reason is 'unexpected'
I'm not aware of any actual cases of this happening. But with a totally unexpected error, we don't really have reason to hope that infinite-retrying will help a /register succeed, so we should abort and let the user know.
1 parent 091d9ed commit 11cbbd1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/message/fetchActions.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ export const registerAbort = (reason: RegisterAbortReason): ThunkAction<Promise<
224224
getState,
225225
) => {
226226
dispatch(registerAbortPlain(reason));
227-
if (getHaveServerData(getState())) {
227+
if (getHaveServerData(getState()) && reason !== 'unexpected') {
228228
// Try again, forever if necessary; the user has an interactable UI and
229229
// can look at stale data while waiting.
230230
//

0 commit comments

Comments
 (0)