Fix bug in duplicate ticket check