Skip to content

Commit

Permalink
ensure mutated strings are mutable (#196)
Browse files Browse the repository at this point in the history
  • Loading branch information
mitchellhenke authored May 15, 2024
1 parent 30e3f6f commit 1b687d8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/rack/timeout/core.rb
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ def call(env)
timeout = RT::Scheduler::Timeout.new do |app_thread| # creates a timeout instance responsible for timing out the request. the given block runs if timed out
register_state_change.call :timed_out

message = "Request "
message = +"Request "
message << "waited #{info.ms(:wait)}, then " if info.wait
message << "ran for longer than #{info.ms(:timeout)} "
if term_on_timeout
Expand Down
2 changes: 1 addition & 1 deletion lib/rack/timeout/logging-observer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def log_state_change(env)
info = env[::Rack::Timeout::ENV_INFO_KEY]
level = STATE_LOG_LEVEL[info.state]
logger(env).send(level) do
s = "source=rack-timeout"
s = +"source=rack-timeout"
s << " id=" << info.id if info.id
s << " wait=" << info.ms(:wait) if info.wait
s << " timeout=" << info.ms(:timeout) if info.timeout
Expand Down

0 comments on commit 1b687d8

Please sign in to comment.