From 1ec1a26a702c97fd3a56fecee4957eadb99253b1 Mon Sep 17 00:00:00 2001 From: Manny Dinssa <44172848+Dinssa@users.noreply.github.com> Date: Mon, 16 Sep 2024 16:40:20 +0100 Subject: [PATCH] Use tr instead of gsub --- app/helpers/application_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 847318fb1..2a91006b0 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -34,7 +34,7 @@ module ApplicationHelper def sanitise_characters(string) return string unless string - string.gsub("'", "’").gsub("&", "&") + string.tr("'", "’").tr("&", "&") end private