Replaced line check with a regular expression for wider set of lines to transform.
The transformation is now applied to lines containing an arbitrary number of opening braces, followed by an arbitrary number of closing braces, followed by an optional semicolon, all interspersed with arbitray whitespace.
This matches more lines while still keeping the spirit of the extension.
For example, it now matches an empty body ("{}") and the closing of multiple namespaces ("}}}").