From 20ba1cf2aeef0e60d8eee24bdf9e17846aa1deaf Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Sat, 29 Nov 2025 08:58:48 -0800 Subject: [PATCH] Ensure mutable string is used to prevent warning --- app/models/webhook.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/webhook.rb b/app/models/webhook.rb index 1afefa6..d8e7b43 100644 --- a/app/models/webhook.rb +++ b/app/models/webhook.rb @@ -53,7 +53,7 @@ class Webhook < ApplicationRecord end def extract_text_from(response) - response.body.dup.force_encoding("UTF-8") if response.code == "200" && response.content_type.in?(%w[ text/html text/plain ]) + String.new(response.body).force_encoding("UTF-8") if response.code == "200" && response.content_type.in?(%w[ text/html text/plain ]) end def receive_text_reply_to(room, text:)