[utils] function that filters empty values, strips and joins values in a list