method
serialize_hash_key
v5.0.0.1 -
Show latest stable
- Class:
ActiveJob::Arguments
serialize_hash_key(key)private
No documentation available.
# File activejob/lib/active_job/arguments.rb, line 138
def serialize_hash_key(key)
case key
when *RESERVED_KEYS
raise SerializationError.new("Can't serialize a Hash with reserved key #{key.inspect}")
when String, Symbol
key.to_s
else
raise SerializationError.new("Only string and symbol hash keys may be serialized as job arguments, but #{key.inspect} is a #{key.class}")
end
end