You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 17, 2018. It is now read-only.
It's confusing that the count method is included on a resource without dm-aggregates being included. What's more confusing is it appears to return the proper count when no query hash is specified but otherwise will always return 0.
I think #count is coming from Enumerable in 1.8.7+, but to avoid confusion we should probably use undef_method :count in Model and Collection.
We should probably also look at doing the same for :min, :max and other methods that are provided by dm-aggregates. I would’ve wished that we didn’t have knowledge of which dm-aggregates’ methods are in dm-core, since I think that screws up the dependency chain, but I don’t know if we can get around it.
by Dan Kubb (dkubb)
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
It's confusing that the count method is included on a resource without dm-aggregates being included. What's more confusing is it appears to return the proper count when no query hash is specified but otherwise will always return 0.
Created by Alex - 2010-08-10 17:09:31 UTC
Original Lighthouse ticket: http://datamapper.lighthouseapp.com/projects/20609/tickets/1384
The text was updated successfully, but these errors were encountered: