Set all attributes at the same time otherwise old ones get lost
Merge pull request #15 from mwhuss/fix-attributes

Set all attributes at the same time otherwise old ones get lost