refine coding style