[web] Fix HEAD request handling (closes #3677949) [applied]