The ideal response of the OnChange trigger usually starts at index 1 but when a row from index 1 is sorted to index 3 or skipped a row. The next return of the index parameter will start at index 0 instead of 1.
This image is the ideal index return before I skipped a row sorting.
This image is the return of the OnChange index after I sorted a row from index 1 to 3.
Sort Scenario:
1.) From Row 1 to Row 2. ( New Index = 2, Old Index = 1 No issue)
2.) From Row 1 to Row 3. ( New Index = 3, Old Index = 1 No issue)
3.) From Row 1 to Row 2 (New Index = 1, Old Index = 0 Issue)
Can you share the complete picture(flow) of your Handler (client action) ?