Add is_configurable field
Use single source of attribute's data
Move code to a separate method and use it in different places