defaulting usernumber to '' (root login)
authortipaul <tipaul>
Fri, 14 Apr 2006 09:33:56 +0000 (09:33 +0000)
committertipaul <tipaul>
Fri, 14 Apr 2006 09:33:56 +0000 (09:33 +0000)
C4/Log.pm

index 9e5f76c..a64720a 100644 (file)
--- a/C4/Log.pm
+++ b/C4/Log.pm
@@ -62,6 +62,7 @@ Adds a record into action_logs table to report the different changes upon the da
 #'
 sub logaction{
   my ($usernumber,$modulename, $actionname, $objectnumber, $infos)=@_;
+       $usernumber='' unless $usernumber;
        my $dbh = C4::Context->dbh;
        my $sth=$dbh->prepare("Insert into action_logs (timestamp,user,module,action,object,info) values (now(),?,?,?,?,?)");
        $sth->execute($usernumber,$modulename,$actionname,$objectnumber,$infos);