Bug fixed when retrieving the last match.