Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-5488

Date.__evolve_time__ ignores Rails timezone

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Unknown Unknown
    • 9.0.0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Minor Change

      When evolving a Date into a Time when querying, the following method is used:

      def __evolve_time__
        ::Time.local(year, month, day)
      end

      I believe Time.local will ignore Time.zone from Rails.

      Instead, it should do the same as Mongoize, which is use

      ::Time.configured.local(year, month, day)

            Assignee:
            oleg.pudeyev@mongodb.com Oleg Pudeyev (Inactive)
            Reporter:
            shields@tablecheck.com Johnny Shields
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: