Fixed an incorrect array dereference