only conditionally implode $type