changed attribs property to be an object and not an array