fixed bug and arrange format