This chunk here seems like it could take advantage of calling `join_clauses` below.