Limit and count don't work together, unless defining lazy

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Done
    • 3.1.3
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      I'm trying to get 5 items from my db
      Shop::CartItems.limit(5).count #=> 21

      It only returns 5 if I say lazy
      Shop::CartItems.limit(5).lazy.count #=> 5

      I read something about count taking on a boolean, but I couldn't get that to work and I didn't find anything in the docs either.

      Should this work like this? Am I doing something wrong?

            Assignee:
            Unassigned
            Reporter:
            deiga
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: