[Bps-public-commit] r9718 - bpsbuilder/BPB/lib/BPB

sunnavy at bestpractical.com sunnavy at bestpractical.com
Wed Nov 21 07:39:40 EST 2007


Author: sunnavy
Date: Wed Nov 21 07:39:40 2007
New Revision: 9718

Modified:
   bpsbuilder/BPB/lib/BPB/Backend.pm

Log:
tiny improvement for Backend.pm

Modified: bpsbuilder/BPB/lib/BPB/Backend.pm
==============================================================================
--- bpsbuilder/BPB/lib/BPB/Backend.pm	(original)
+++ bpsbuilder/BPB/lib/BPB/Backend.pm	Wed Nov 21 07:39:40 2007
@@ -7,8 +7,9 @@
 
 =head2 new
 
-accept the backend part(hash instead of hashref) and project part
-in the config.yml as args. returns the individual Backend objects.
+accept the backend part in config as args.
+e.g ( module => 'SVK', project => 'test', ... )
+returns the the individual Backend object.
 
 =cut
 
@@ -21,7 +22,7 @@
     croak "need a backend module, please check your config" unless $module;
     croak "need project option" unless $args{project};
 
-    $module = 'BPB::Backend::' . $module if $module !~ /::/;
+    $module = 'BPB::Backend::' . $module unless $module =~ /^BPB::Backend/;
 
     $module->require or die $@;
 



More information about the Bps-public-commit mailing list