Cursor update and counter fix