Thread:Extension talk:ParserFunctions/ switch Optimization?

I was looking at the code for #switch, it struck me odd that once a match was found, it continued to try to match subsequent single values. The solution is to replace lines #170 (" ") with " " and #221 (" ") with " ".