From e51e49dfe41376fba8061a923c6b836212aa907b Mon Sep 17 00:00:00 2001 From: Tony Drake Date: Wed, 8 Oct 2025 16:46:24 -0400 Subject: [PATCH] Fix "expires in" message in blocked jobs table The `bidirectional_time_distance_in_words_with_title` helper outputs a html-safe span tag. However it is used in string interpolation in the blocked jobs table making which is not html-safe by default resulting in the the raw html being displayed on the page. This calls `#html_safe` on the string to not escape the markup. --- app/views/mission_control/jobs/jobs/blocked/_job.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/mission_control/jobs/jobs/blocked/_job.html.erb b/app/views/mission_control/jobs/jobs/blocked/_job.html.erb index 274f2844..3db2aacf 100644 --- a/app/views/mission_control/jobs/jobs/blocked/_job.html.erb +++ b/app/views/mission_control/jobs/jobs/blocked/_job.html.erb @@ -1,7 +1,7 @@ <%= link_to job.queue_name, application_queue_path(@application, job.queue) %>
<%= job.blocked_by %>
-
<%= job.blocked_until ? "Expires #{bidirectional_time_distance_in_words_with_title(job.blocked_until)}" : "" %>
+
<%= job.blocked_until ? "Expires #{bidirectional_time_distance_in_words_with_title(job.blocked_until)}".html_safe : "" %>
<%= render "mission_control/jobs/jobs/blocked/actions", job: job %>