fixing bug in previous commit