refine the bugfix