ahmadawais / corona-cli

🦠 Track the Coronavirus disease (COVID-19) in the command line. Worldwide for all countries, for one country, and the US States. Fast response time (< 100ms). To chat: https://twitter.com/MrAhmadAwais/
https://NodeCLI.com
MIT License
1.85k stars 191 forks source link

🐛 FIX: Sorting China #73

Closed nezia1 closed 4 years ago

nezia1 commented 4 years ago

Fixed issue #68. The API ordered everything descending by default, except China for some reason. Edit: I just noticed that I tagged the wrong issue when committing, could you change that?

marvinjude commented 4 years ago

Hi @Nezia1 you can edit the comment to point to the right issue.

ahmadawais commented 4 years ago

This would make the call slow, it would be reordering all data and then limiting it. Can we improve that? What's the issue there? Why is it happening? I haven't dug deep

nezia1 commented 4 years ago

The issue is basically that the API orders by default in a descending order, but places China at the bottom for some reason. I don't think we have much choice here, unless we can find a more optimal way of doing it?

ahmadawais commented 4 years ago

Thank you! 👌

ahmadawais commented 4 years ago

🔗 https://github.com/ahmadawais/corona-cli/releases/tag/4.0.0 🔗 https://www.npmjs.com/package/corona-cli

nezia1 commented 4 years ago

No problem! 😊