lib/dry/schema/macros/core.rb in dry-schema-1.4.1 vs lib/dry/schema/macros/core.rb in dry-schema-1.4.2
- old
+ new
@@ -26,11 +26,11 @@
# @api private
option :schema_dsl, optional: true
# @api private
- def new(options = EMPTY_HASH)
- self.class.new({ name: name, compiler: compiler, schema_dsl: schema_dsl }.merge(options))
+ def new(**options)
+ self.class.new(name: name, compiler: compiler, schema_dsl: schema_dsl, **options)
end
# @api private
def to_rule
compiler.visit(to_ast)