Fix Auto-Completion OutOfBoundsException when there's only one open ticket.
This also fixes auto completion skipping the first ticket.