+--------------------------------------------------------------------+
| CiviCRM version 4.6 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014 |
+ | Copyright CiviCRM LLC (c) 2004-2015 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
| GNU Affero General Public License or the licensing of CiviCRM, |
| see the CiviCRM license FAQ at http://civicrm.org/licensing |
+--------------------------------------------------------------------+
-*/
+ */
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-2014
+ * @copyright CiviCRM LLC (c) 2004-2015
* $Id$
*
*/
/**
* Logs with an arbitrary level.
*
- * @param mixed $level
- * @param string $message
- * @param array $context
- * @return null
- */
- /**
* @param mixed $level
* @param string $message
* @param array $context
*
- * @return null
*/
public function log($level, $message, array $context = array()) {
- if(!isset($context['hostname'])) {
+ if (!isset($context['hostname'])) {
$context['hostname'] = CRM_Utils_System::ipAddress();
}
$rec = new CRM_Core_DAO_SystemLog();
$rec->context = json_encode($context);
$rec->save();
}
+
}