thegreenwebfoundation / co2.js

An npm module for accessing the green web API, and estimating the carbon emissions from using digital services
Other
385 stars 48 forks source link

Fix greencheck multi response #123

Closed fershad closed 1 year ago

fershad commented 1 year ago

This PR fixes the response for green hosting checks when an array of domains are provided.

Previously, this check returned an empty array []. This was caused by a couple of factors:

This PR fixes both of those errors. It also updates some of the tests to use the API, rather than a local database.

fershad commented 1 year ago

I also deleted an old readme file in the src directory (https://github.com/thegreenwebfoundation/co2.js/pull/123/files#diff-9ca8f47f3b7fb128a4427ac4122e36ec1efc645ba984bac232c62d3a8d0d2571), since the content it out of date and has been superseded by the developer docs website.