Exemple #1
0
 /**
  * Adds some extra info to the loggin of files
  * @param string $action the action to log
  * @param boolean $save unused
  * @return boolean if save was successful
  */
 protected function log($action, $save = true)
 {
     $log = parent::log($action, false);
     if (empty($log)) {
         return false;
     }
     if ($log->action == 'update') {
         $log->action = 'propedit';
         if ($log->object->isModified('folder_id')) {
             $log->action = 'moved';
         }
         if ($log->object->isModified('name')) {
             $log->action = 'renamed';
             $log->message = $log->object->getOldAttributeValue('name') . ' > ' . $log->message;
         }
     }
     return $log->save();
 }