mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-16 17:30:43 -07:00
Add to_hash for ResourceLimits for serialization
This commit is contained in:
@@ -19,5 +19,11 @@ module Liquid
|
||||
def reset
|
||||
@render_length = @render_score = @assign_score = 0
|
||||
end
|
||||
|
||||
def to_hash
|
||||
instance_variables.each_with_object({}) do |key, hash|
|
||||
hash[key.to_s[1..-1].to_sym] = instance_variable_get(key)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user