mirror of
https://github.com/sct/overseerr.git
synced 2025-09-17 17:24:35 +02:00
fix(api): Use POST instead of GET for API endpoints that mutate state (#877)
This commit is contained in:
@@ -30,7 +30,7 @@ const RequestBlock: React.FC<RequestBlockProps> = ({ request, onUpdate }) => {
|
||||
|
||||
const updateRequest = async (type: 'approve' | 'decline'): Promise<void> => {
|
||||
setIsUpdating(true);
|
||||
await axios.get(`/api/v1/request/${request.id}/${type}`);
|
||||
await axios.post(`/api/v1/request/${request.id}/${type}`);
|
||||
|
||||
if (onUpdate) {
|
||||
onUpdate();
|
||||
|
Reference in New Issue
Block a user