Do not write attribute if it is blank