added function to remove all white spaces