fix numerous issues with status headers