Some rafactoring