Fixing headers for non 200 responses