harphub / harpVis

Visualisation functions for harp.
https://harphub.github.io/harpVis/
Other
1 stars 16 forks source link

robust sorting of dates #36

Closed leneoMET closed 3 years ago

andrew-MET commented 3 years ago

Thanks for the quick PR.

I moved the sorting to inside the !is.null to make sure the app doesn't crash when it has no data to fill the select.

Also there are some styling considerations to help readability I should have told you about:

In general we try to follow the tidyverse style guide

Also, dplyr / tidyr column selections need to be preceded by the .data pronoun, i.e. .data$colname. This prevents errors when running R CMD CHECK on the package.

Otherwise I think this fixes #26

leneoMET commented 3 years ago

Thanks for the corrections! I should have seen that the sorting should be inside !is.null. I will look into the tidyverse style guide for future commits.