Regex fixes to resolve issue #10