From 9737bc6b69551b7a045d13cb6265e31c9a085e35 Mon Sep 17 00:00:00 2001 From: Adam Lassek Date: Mon, 13 Jun 2022 15:00:45 -0500 Subject: [PATCH] Fix incorrect type in ManifestRegistrar#finalize! `#finalize!` is sending the basename directly to `#call`, which expects a Dry::System::Identifier. This means that if you configure a `registrations_dir`, putting any file in that directory will lead to an exception during finalization. This appears to have been introduced during #208 --- lib/dry/system/manifest_registrar.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/dry/system/manifest_registrar.rb b/lib/dry/system/manifest_registrar.rb index 62c7fded7..975fcafac 100644 --- a/lib/dry/system/manifest_registrar.rb +++ b/lib/dry/system/manifest_registrar.rb @@ -27,7 +27,7 @@ def initialize(container) # @api private def finalize! ::Dir[registrations_dir.join(RB_GLOB)].sort.each do |file| - call(File.basename(file, RB_EXT)) + call(Identifier.new(File.basename(file, RB_EXT))) end end