lib/acfs/resource/service.rb in acfs-1.5.1 vs lib/acfs/resource/service.rb in acfs-1.6.0

- old
+ new

@@ -32,11 +32,11 @@ # # @param klass [Class] Service class derived from {Acfs::Service}. # @param options [Object] Option delegated to # service class initializer. # - def service(klass = nil, options = {}) - return (@service = klass.new options) if klass + def service(klass = nil, **options) + return (@service = klass.new(**options)) if klass @service || superclass.service end end end