Changed the addAttribute method so that if a blank attribute is written, it is treated as a null