out of bounds bug fix