Fix bug when first argument of create_element is an array