Updated idempotent option, now uses Regexp.escape