Remove redundant module
Add more complex function for trimming whitespaces