some code tweak