die() instead of silently skip files with extensions we can't handle
Brian Cassidy [Tue, 22 Apr 2008 19:35:28 +0000 (19:35 +0000)]
Changes
lib/Catalyst/Plugin/ConfigLoader.pm

diff --git a/Changes b/Changes
index f0a843e..81090a5 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,8 +1,9 @@
 Revision history for Perl extension Catalyst::Plugin::ConfigLoader.
 
-    - Updated pod with new example
 0.20  Wed Feb 06 2008
     - sort configs by filename for loading (RT #31498)
+    - Updated pod with new example
+    - die() instead of silently skip files with extensions we can't handle
 
 0.19  Wed Nov 21 2007
     - fixed suffix appending to explicit config paths
index 00e6a6b..04ac7e3 100644 (file)
@@ -126,7 +126,8 @@ sub find_files {
 
     my @files;
     if ( $extension ) {
-        next unless grep { $_ eq $extension } @extensions;
+        die "Unable to handle files with the extension '${extension}'"
+            unless grep { $_ eq $extension } @extensions;
         ( my $local = $path ) =~ s{\.$extension}{_$suffix.$extension};
         push @files, $path, $local;
     }