Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-1666

Constants for operators

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • API
    • None
    • Fully Compatible

    Description

      Would it be possible to define constants for the mongo operators somewhere in the library? e.g.

      const (
        Set = "$set"
        Unset = "$unset"
        CurrentDate = "$currentDate"
        .....
      )

       

      We recently started using sonarqube and it rightly so complains about duplicating strings in the code more than x times.

       

      We maintain an internal set of libraries where we could also consider adding these but I would assume more people would benefit from having these into the core library.

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            b.wilsonhunt@faceit.com Bradley Wilson-Hunt
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: