ExpDev07 / coronavirus-tracker-api

🦠 A simple and fast (< 200ms) API for tracking the global coronavirus (COVID-19, SARS-CoV-2) outbreak. It's written in python using the 🔥 FastAPI framework. Supports multiple sources!
https://coronavirus-tracker-api.herokuapp.com
GNU General Public License v3.0
1.59k stars 323 forks source link

Aggregation pattern implemented - CountryCode #377

Closed ashnaw closed 3 years ago

ashnaw commented 3 years ago

Modified Files:

'app/location/__init.py' 'app/utils/countries.py'

Created JsonFile: 'country_name_country_code_path.json'

Modified the file 'app/location/init.py' to implement the AGGREGATION pattern.

Replaces the original way of accessing the country_code. Rather than accessing it as a globally accessible object, the country code is now only accessible through an instance of the class 'CountryCodeUtil' which acts as the root in the boundary.

ExpDev07 commented 3 years ago

I assume this is also part of "assignment 8"? Closing as I don't believe this is necessary for the project at this stage.