Some code refine