-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
The new Psych version required by Ruby 3.1 no longer allows the loading of arbitrary classes into YAML by default. We switch to `#safe_load` and enable the class we're currently using. See: ruby/psych@cb50aa8 ruby/psych@1764942 [skip ci]
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ class LogEntry < Spree::Base | |
belongs_to :source, polymorphic: true, optional: true | ||
|
||
def parsed_details | ||
@details ||= YAML.load(details) | ||
@details ||= YAML.safe_load(details, permitted_classes: [ActiveMerchant::Billing::Response]) | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
jarednorman
Member
|
||
end | ||
end | ||
end |
Hi @waiting-for-dev ,
Is this backward with ruby < 3.1? I've got an error with this part using ruby 2.7.6