clean up array to string conversion functions