Skip to content

Commit

Permalink
Replace OpenStruct with Struct
Browse files Browse the repository at this point in the history
> warning: ostruct was loaded from the standard library, but will no
> longer be part of the default gems starting from Ruby 3.5.0.
  • Loading branch information
dentarg committed Feb 7, 2025
1 parent 1bd5e00 commit 8371149
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
3 changes: 1 addition & 2 deletions lib/foreman/export/base.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
require "foreman/export"
require "ostruct"
require "pathname"
require "shellwords"

Expand Down Expand Up @@ -35,7 +34,7 @@ def template
def @engine.procfile
Foreman::Export::Base.warn_deprecation!
@processes.map do |process|
OpenStruct.new(
Struct.new(
:name => @names[process],
:process => process
)
Expand Down
1 change: 0 additions & 1 deletion spec/foreman/process_spec.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
require 'spec_helper'
require 'foreman/process'
require 'ostruct'
require 'timeout'
require 'tmpdir'

Expand Down

0 comments on commit 8371149

Please sign in to comment.