fixing bug'