cleanup and fixing bug RE: default header arguments on export