Cleanup some more element code