Fix attributes merge

[closes #1358]