Updated the Element class