Fixed silly counter mistake (#1945)
Fixed test for #1945