bug fix after the feedback