clean up element variables