refactor(filterData):remove duplicated code to filter sensitive data from user object