I think this can be made cleaner by having the quote match excluded from the actual matching string.  Maybe I'll give that a try and post an update.