refine register method