fix: Allow overriding home/root
Marcus Ramberg [Thu, 23 Jun 2005 19:32:43 +0000 (19:32 +0000)]
Changes
lib/Catalyst/Setup.pm

diff --git a/Changes b/Changes
index b3929ff..6b86d02 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,6 +1,7 @@
 This file documents the revision history for Perl extension Catalyst.
 
-5.24  2005-00-00 00:00:00
+5.30  2005-00-00 00:00:00
+        - Allow overriding home/root in config.
         - make module build cons README automatically.
         - prettify home path by resolving '..' (Andy Grundman)
         - improved helper templates a bit, new naming scheme for tests...
index d3b1da1..be83e17 100644 (file)
@@ -360,8 +360,8 @@ sub setup_home {
     }
 
     if ( $home ) {
-        $class->config->{home} = $home;
-        $class->config->{root} = dir($home)->subdir('root');
+        $class->config->{home} ||= $home;
+        $class->config->{root} ||= dir($home)->subdir('root');
     }
 }