[siesta-commit] siesta/lib/Siesta/Storage DBI.pm,1.14,1.15

[prev] [thread] [next] [lurker] [Date index for 2002/09/09]

From: muttley
Subject: [siesta-commit] siesta/lib/Siesta/Storage DBI.pm,1.14,1.15
Date: 09:42 on 09 Sep 2002
Update of /cvsroot/siesta/siesta/lib/Siesta/Storage
In directory usw-pr-cvs1:/tmp/cvs-serv26868/lib/Siesta/Storage

Modified Files:
	DBI.pm 
Log Message:
F1XX0r3d


Index: DBI.pm
===================================================================
RCS file: /cvsroot/siesta/siesta/lib/Siesta/Storage/DBI.pm,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- DBI.pm	8 Sep 2002 17:48:40 -0000	1.14
+++ DBI.pm	9 Sep 2002 08:42:40 -0000	1.15
@@ -31,6 +31,7 @@
                                   map { "$_ = '$where{$_}'" } keys %where)
                  ) if %where;
 
+
     return map {
         my %foo;
         @foo{@columns} = @$_;
@@ -322,20 +323,27 @@
 sub get_config {
     my ($self, $namespace, $user_id, $list_id, $key) = @_;
 
-    unless (($user_id eq '')  || ($list_id eq '')) {
+
+	
+    $user_id ||= '';
+    $list_id ||= '';
+
+
+    unless ($user_id eq '' || $list_id eq '') {
         my $return = $self->get_config_explicitly($namespace, $user_id, $list_id, $key);
         return $return
-          if defined $return;
+       		if defined $return;
     }   
 
-    unless ($user_id eq '') {
-        my $return = $self->get_config_explicitly($namespace, '', $list_id, $key);
+
+    unless  ($user_id eq '') {
+        my $return = $self->get_config_explicitly($namespace, $user_id, '', $key);
         return $return 
           if defined $return;
     }   
 
     unless ($list_id eq '') {
-        my $return = $self->get_config_explicitly($namespace, $user_id, '', $key);
+        my $return = $self->get_config_explicitly($namespace, '', $list_id,  $key);
         return $return
           if defined $return;
     }   
@@ -348,6 +356,7 @@
 # namespace, user, list, key tuple. 
 sub get_config_explicitly {
     my ($self, $namespace, $user_id, $list_id, $key) = @_;
+
 
     # just to be sure
     $user_id ||= '';



Generated at 13:57 on 01 Jul 2004 by mariachi 0.52