Cleaning out empty selectors and trailing spaces