Skip to content

Commit

Permalink
docs: Fix sample code to avoid reading from undefined in `didAuthEr…
Browse files Browse the repository at this point in the history
…ror` (#3723)
  • Loading branch information
ghengeveld authored Jan 23, 2025
1 parent 0f29d07 commit b03198a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/advanced/authentication.md
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ authExchange(async utils => {
return {
// ...
didAuthError(error, _operation) {
return error.response.status === 401;
return error.response?.status === 401;
},
};
});
Expand Down

0 comments on commit b03198a

Please sign in to comment.