@@ -238,10 +238,6 @@ ngx_http_fastcgi_cache_purge_handler(ngx_http_request_t *r)
238238{
239239 ngx_http_fastcgi_loc_conf_t * flcf ;
240240
241- if (!(r -> method & (NGX_HTTP_GET |NGX_HTTP_HEAD |NGX_HTTP_DELETE ))) {
242- return NGX_HTTP_NOT_ALLOWED ;
243- }
244-
245241 flcf = ngx_http_get_module_loc_conf (r , ngx_http_fastcgi_module );
246242
247243 return ngx_http_cache_purge_handler (r , flcf -> upstream .cache -> data ,
@@ -354,10 +350,6 @@ ngx_http_proxy_cache_purge_handler(ngx_http_request_t *r)
354350{
355351 ngx_http_proxy_loc_conf_t * plcf ;
356352
357- if (!(r -> method & (NGX_HTTP_GET |NGX_HTTP_HEAD |NGX_HTTP_DELETE ))) {
358- return NGX_HTTP_NOT_ALLOWED ;
359- }
360-
361353 plcf = ngx_http_get_module_loc_conf (r , ngx_http_proxy_module );
362354
363355 return ngx_http_cache_purge_handler (r , plcf -> upstream .cache -> data ,
@@ -443,10 +435,6 @@ ngx_http_scgi_cache_purge_handler(ngx_http_request_t *r)
443435{
444436 ngx_http_scgi_loc_conf_t * slcf ;
445437
446- if (!(r -> method & (NGX_HTTP_GET |NGX_HTTP_HEAD |NGX_HTTP_DELETE ))) {
447- return NGX_HTTP_NOT_ALLOWED ;
448- }
449-
450438 slcf = ngx_http_get_module_loc_conf (r , ngx_http_scgi_module );
451439
452440 return ngx_http_cache_purge_handler (r , slcf -> upstream .cache -> data ,
@@ -537,10 +525,6 @@ ngx_http_uwsgi_cache_purge_handler(ngx_http_request_t *r)
537525{
538526 ngx_http_uwsgi_loc_conf_t * ulcf ;
539527
540- if (!(r -> method & (NGX_HTTP_GET |NGX_HTTP_HEAD |NGX_HTTP_DELETE ))) {
541- return NGX_HTTP_NOT_ALLOWED ;
542- }
543-
544528 ulcf = ngx_http_get_module_loc_conf (r , ngx_http_uwsgi_module );
545529
546530 return ngx_http_cache_purge_handler (r , ulcf -> upstream .cache -> data ,
0 commit comments