/**
  * Insert a new log into the database, filtering sensitive information
  * and encoding data for storage.
  *
  * @param array $data
  * @return JwActivityLog_Action
  */
 public function create($data)
 {
     // Meta data
     $data['actionDateTime'] = date("Y-m-d H:i:s");
     $data['resourceUrl'] = $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF'] . '?' . $_SERVER['QUERY_STRING'];
     // Remove sensitive information
     if (isset($data['userAccountData']['userPassword'])) {
         unset($data['userAccountData']['userPassword']);
     }
     if (isset($data['userAccountData']['userHash'])) {
         unset($data['userAccountData']['userHash']);
     }
     // Encode for storage
     $data['userAccountData'] = PerchUtil::json_safe_encode($data['userAccountData']);
     return parent::create($data);
 }
 /**
  * Insert a new record into the database
  *
  * @param array $data
  *
  * @return bool
  */
 public function create($data)
 {
     $data['addressUpdated'] = date('Y-m-d H:i:s');
     return parent::create($data);
 }