Fixed a crasher in the match brackets logic that was causing the duplicated brackets Stephen reported.

Leo build: 20141104103337