Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 4b02817

Browse files
committedFeb 20, 2021
Change request: Fixed typo in data for issue reporting. Only display error message for server errors.
1 parent 1e18101 commit 4b02817

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed
 

‎src/components/ReportPopup/index.jsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,14 @@ function ReportPopup() {
3232
})
3333
.catch((err) => {
3434
setIsLoading(false);
35-
toastr.error("Report failed", err.message);
35+
36+
// Response interceptor passes only error body
37+
// use this to identify server-side errors
38+
if (err instanceof Error) {
39+
toastr.error("Report failed");
40+
} else {
41+
toastr.error("Report failed", err.message);
42+
}
3643
});
3744
};
3845

‎src/services/teams.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ export const postReport = (teamName, teamId, reportText, memberHandle) => {
181181
template: "team-issue-report",
182182
data: {
183183
projectName: teamName,
184-
projected: teamId,
184+
projectId: teamId,
185185
reportText,
186186
},
187187
};

0 commit comments

Comments
 (0)
This repository has been archived.