lib/rubysmith/configuration/transformers/template_root.rb in rubysmith-6.6.0 vs lib/rubysmith/configuration/transformers/template_root.rb in rubysmith-6.9.0

- old
+ new

@@ -4,25 +4,25 @@ require "refinements/array" module Rubysmith module Configuration module Transformers - # Appends custom content to default template roots. + # Appends custom path to default template roots. class TemplateRoot include Dry::Monads[:result] using Refinements::Array def initialize key = :template_roots, default: Pathname(__dir__).join("../../templates") @key = key @default = default end - def call content + def call attributes Array(default).map { |path| Pathname path } - .including(content[key]) + .including(attributes[key]) .compact - .then { |value| Success content.merge!(key => value) } + .then { |value| Success attributes.merge!(key => value) } end private attr_reader :key, :default