fix wrong axis in bounds check