fixes #6384 do not send headers in case total values are calculated