Skip to content

Commit

Permalink
Update country_code.py
Browse files Browse the repository at this point in the history
  • Loading branch information
mikkokotila committed Mar 7, 2019
1 parent 37627bc commit cc14a0d
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions astetik/utils/country_code.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,8 @@

import pkg_resources

try:
countries = pkg_resources.resource_filename('astetik', 'extras/countries.csv')
countries = pd.read_csv(countries)
# yes, that's right, swallow everything :)
except:
countries = 'https://raw.githubusercontent.com/mikkokotila/astetik/master/astetik/extras/countries.csv'
countries = pd.read_csv(countries)
countries = pkg_resources.resource_filename(__name__, '../extras/countries')
countries = pd.read_csv(countries)


def code_to_country(code):
Expand Down

0 comments on commit cc14a0d

Please sign in to comment.