Skip to content

Commit

Permalink
fixed issue where there is no 2014 cpi data
Browse files Browse the repository at this point in the history
  • Loading branch information
econchick committed Feb 10, 2014
1 parent 5231200 commit c46d1cc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions apis/platform_pricing.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,9 @@ def get_adjusted_price(self, price, year, current_year=None):
This essentially is the calculated inflation for an item.
"""
if current_year is None:
current_year = datetime.datetime.now().year
if current_year is None or current_year > 2013:
current_year = 2013

# If our data range doesn't provide a CPI for the given year, use
# the edge data.
if year < self.first_year:
Expand Down

0 comments on commit c46d1cc

Please sign in to comment.