diff options
| author | Samantaz Fox <coding@samantaz.fr> | 2022-02-03 04:24:31 +0100 |
|---|---|---|
| committer | Samantaz Fox <coding@samantaz.fr> | 2022-02-03 04:24:31 +0100 |
| commit | ba37259258277aafb6fc700dabecead695bd624e (patch) | |
| tree | 4221b59e6126e4c30f24a8a6394e9461e17bf7de /src | |
| parent | eca8d2e7d72d142c7509f2f6cfb8f96a915bb77d (diff) | |
| download | invidious-ba37259258277aafb6fc700dabecead695bd624e.tar.gz invidious-ba37259258277aafb6fc700dabecead695bd624e.tar.bz2 invidious-ba37259258277aafb6fc700dabecead695bd624e.zip | |
Also propagate changes to watch ECR page
Diffstat (limited to 'src')
| -rw-r--r-- | src/invidious/views/watch.ecr | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/invidious/views/watch.ecr b/src/invidious/views/watch.ecr index 00f5f8b7..2e0aee99 100644 --- a/src/invidious/views/watch.ecr +++ b/src/invidious/views/watch.ecr @@ -321,11 +321,11 @@ we're going to need to do it here in order to allow for translations. </div> <div class="pure-u-10-24" style="text-align:right"> - <% if views = rv["short_view_count_text"]?.try &.delete(", views watching") %> - <% if !views.empty? %> - <b class="width:100%"><%= translate_count(locale, "generic_views_count", views.to_i? || 0) %></b> - <% end %> - <% end %> + <b class="width:100%"><%= + views = rv["view_count"]?.try &.to_i? + views ||= rv["view_count_short"]?.try { |x| short_text_to_number(x) } + translate_count(locale, "generic_views_count", views || 0, NumberFormatting::Short) + %></b> </div> </h5> </a> |
