Skip to content

Commit

Permalink
fix aggregate provider and client counts. #166
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin Fenner committed Dec 28, 2018
1 parent ce5ba3f commit ca46125
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/models/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ def year
# count years account has been active. Ignore if deleted the same year as created
def cumulative_years
if deleted_at && deleted_at.year > created_at.year
(created_at.year..deleted_at.year).to_a
(created_at.year...deleted_at.year).to_a
elsif deleted_at
[]
else
Expand Down
2 changes: 1 addition & 1 deletion app/models/provider.rb
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def year
# count years account has been active. Ignore if deleted the same year as created
def cumulative_years
if deleted_at && deleted_at.year > created_at.year
(created_at.year..deleted_at.year).to_a
(created_at.year...deleted_at.year).to_a
elsif deleted_at
[]
else
Expand Down

0 comments on commit ca46125

Please sign in to comment.