trim removed to avoid null pointer exception