Bugfix: readAttribute should return undefined if no data provided