Skip to content

Commit eb96356

Browse files
committed
updated put to patch
1 parent 01f1582 commit eb96356

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/utils/ticket.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ export const updateTicket = async function (updates) {
102102
try {
103103
this.setState({
104104
ticket: (
105-
await axios.put(
105+
await axios.patch(
106106
`${BASE_URL}/ticket/${this.state.ticket._id}`,
107107
updates,
108108
{ cancelToken: this.axiosCancel.token }
@@ -121,7 +121,7 @@ export const upvoteComment = async function (commentId) {
121121
try {
122122
this.setState({
123123
ticket: (
124-
await axios.put(
124+
await axios.patch(
125125
`${BASE_URL}/ticket/${this.state.ticket._id}/comment/${commentId}/upvote`,
126126
{},
127127
{ cancelToken: this.axiosCancel.token }
@@ -140,7 +140,7 @@ export const downvoteComment = async function (commentId) {
140140
try {
141141
this.setState({
142142
ticket: (
143-
await axios.put(
143+
await axios.patch(
144144
`${BASE_URL}/ticket/${this.state.ticket._id}/comment/${commentId}/downvote`,
145145
{},
146146
{ cancelToken: this.axiosCancel.token }

0 commit comments

Comments
 (0)