Skip to content

Commit

Permalink
Don't set an end date for the current term
Browse files Browse the repository at this point in the history
The way we generate term dates is to look for the earliest and latest
dates of memberships in that term. But that means that we set the end
date of the current term to the latest end_date of any Membership in it.
Instead we should explicitly delete that date.
  • Loading branch information
tmtmtmtm committed Nov 28, 2016
1 parent 99ade5a commit ac5dd31
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions scraper.rb
Expand Up @@ -106,4 +106,6 @@ def scrape_person(id, icon)
end_date: ds.map(&:last).compact.max,
}
end
# Don't set the date of the current term to the latest resignation date
term_data.last[:end_date] = nil
ScraperWiki.save_sqlite([:id], term_data, 'terms')

0 comments on commit ac5dd31

Please sign in to comment.