refactoring of attributes for better correctness