commit afc2fc4fa5f19b592dd8f09d6397fd244adfbe91 Author: Karsten Loesing karsten.loesing@gmx.net Date: Fri Aug 3 10:32:57 2018 +0200
Fix bug in generating Tor Messenger CSV file. --- src/main/R/rserver/graphs.R | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/main/R/rserver/graphs.R b/src/main/R/rserver/graphs.R index 56c8a55..12a80e9 100644 --- a/src/main/R/rserver/graphs.R +++ b/src/main/R/rserver/graphs.R @@ -1489,7 +1489,8 @@ plot_webstats_tm <- function(start_p, end_p, path_p) { write_webstats_tm <- function(start_p = NULL, end_p = NULL, path_p) { prepare_webstats_tm(start_p, end_p) %>% rename(date = log_date) %>% - spread(request_type, count) %>% + mutate(request_type = factor(request_type, levels = c("tmid", "tmup"))) %>% + spread(request_type, count, drop = FALSE) %>% rename(initial_downloads = tmid, update_pings = tmup) %>% write.csv(path_p, quote = FALSE, row.names = FALSE, na = "") }
tor-commits@lists.torproject.org