We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3da8346 commit 2b1f088Copy full SHA for 2b1f088
CHANGELOG.md
@@ -3,6 +3,7 @@
3
### 8.0.0
4
5
- Drop support to EOL ruby and rails
6
+- Reference ancestor_hierarchies in depth instead of ancestors to avoid n+1
7
8
## [7.4.0](https://github.com/ClosureTree/closure_tree/tree/7.4.0)
9
lib/closure_tree/model.rb
@@ -77,7 +77,7 @@ def leaves
77
end
78
79
def depth
80
- ancestors.size
+ ancestor_hierarchies.size
81
82
83
alias_method :level, :depth
0 commit comments