strip whitespaces from names, if present