Ran
|
Files
6
|
Run time
0s
|
Badge
Embed ▾
README BADGES
|
travis-ci
Do not hit the database for empty ancestries When doing `object.ancestors`, there is a hit to the database even if the ancestry is empty: Area Load (0.4ms) SELECT "areas".* FROM "areas" WHERE 1=0 ORDER BY COALESCE("areas"."ancestry", '') ASC ActiveRecord since 4.0[1] provides an interface to return empty queries that don't hit the database. Let's return that when there is no ancestry to load. [1] https://github.com/rails/rails/commit/8270e4a8c
393 of 413 relevant lines covered (95.16%)
307.72 hits per line
Coverage | ∆ | File | Lines | Relevant | Covered | Missed | Hits/Line |
---|