Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-4758

RegEx query saved wrong in "recent" and "favorites"

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 1.31.3
    • Affects Version/s: 1.26.1
    • Component/s: Query Bar, Query History
    • Labels:
      None
    • Environment:
      windows 10
    • 3
    • Not Needed
    • Iteration Anemone

      Problem Description

      in search history the regex request saved without quotes for flags. => wrong query by usage from history/favorites

      Steps to Reproduce

      search for `{something: /regex/i}`

      Expected Results

      in history there will be `{something: /regex/i}` or `{something: new Regex('regex', 'i'}`

      Actual Results

       `{something: new Regex('regex', i}`

      flag `i` is not quoted.

       

      Additional Notes

        1. buggycompas.jpg
          buggycompas.jpg
          25 kB
        2. screenshot-1.png
          screenshot-1.png
          53 kB

            Assignee:
            leroux.bodenstein@mongodb.com Le Roux Bodenstein
            Reporter:
            dimon.gorelenkov@gmail.com Dmitry GG
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: