refactoring somthing