tweak notifications on errors and other responses

This commit is contained in:
2023-11-05 08:29:36 -07:00
parent 5b7ccf9ef0
commit f43ecc98aa
3 changed files with 55 additions and 56 deletions

View File

@@ -729,8 +729,13 @@ export default class AccountViewView extends Vue {
private handleRateLimitsError(error: unknown) {
if (error instanceof AxiosError) {
const data = error.response?.data as ErrorResponse;
this.limitsMessage = data?.error?.message || "Bad server response.";
console.error("Bad response retrieving limits:", error);
this.limitsMessage =
(data?.error?.message as string) || "Bad server response.";
console.log(
"Got bad response retrieving limits, which usually means user isn't registered. Server says:",
this.limitsMessage,
//error,
);
} else if (
error instanceof Error &&
error.message ===