Skip to content

Commit

Permalink
Fixed missing PATCH method in Access-Control-Allow-Methods if CORS is…
Browse files Browse the repository at this point in the history
… enabled.
  • Loading branch information
Dennis1000 authored and andrea-magni committed Aug 11, 2023
1 parent a9c8d81 commit def1b42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/MARS.Core.Engine.pas
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ procedure TMARSEngine.PatchCORS(const ARequest: IMARSRequest;
Exit;

SetHeaderFromParameter('Access-Control-Allow-Origin', 'CORS.Origin', '*');
SetHeaderFromParameter('Access-Control-Allow-Methods', 'CORS.Methods', 'HEAD,GET,PUT,POST,DELETE,OPTIONS');
SetHeaderFromParameter('Access-Control-Allow-Methods', 'CORS.Methods', 'HEAD,GET,PUT,POST,PATCH,DELETE,OPTIONS');
SetHeaderFromParameter('Access-Control-Allow-Headers', 'CORS.Headers', 'X-Requested-With,Content-Type,Authorization');
end;

Expand Down

0 comments on commit def1b42

Please sign in to comment.