possibly better handling of attributes