Skip to content

Commit

Permalink
updated out of date routes
Browse files Browse the repository at this point in the history
  • Loading branch information
qiandrewj committed Oct 24, 2024
1 parent af97a6a commit 496e214
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion client/src/modules/Course/Components/Course.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ export const Course = () => {
*/
async function reportReview(reviewId: string) {
try {
const response = await axios.post('/api/reportReview', { id: reviewId })
const response = await axios.post('/api/reviews/report', { id: reviewId })
if (response.status === 200) {
setCourseReviews(
courseReviews?.filter((element) => element._id !== reviewId)
Expand Down
2 changes: 1 addition & 1 deletion client/src/modules/Course/Components/ReviewModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ const ReviewModal = ({
* the anonymous modal
*/
async function getNoReviews() {
const response = await axios.post('/api/countReviewsByStudentId', {
const response = await axios.post('/api/profile/count-reviews', {
netId,
})
const res = response.data
Expand Down
2 changes: 1 addition & 1 deletion client/src/modules/Profile/Component/Profile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ const Profile = () => {
*/
async function submitReview(review: NewReview, courseId: string) {
try {
const response = await axios.post('/api/insertReview', {
const response = await axios.post('/api/reviews/insert', {
token: token,
review: review,
courseId: courseId,
Expand Down

0 comments on commit 496e214

Please sign in to comment.