refactoring mapping attributes