Fixed a few logging errors

This commit is contained in:
Abel Hoogeveen 2015-05-01 17:59:40 +02:00
parent b10561df6d
commit 881dcb0ae5
2 changed files with 6 additions and 6 deletions

View File

@ -132,11 +132,11 @@ class Layout extends Bus {
// Load the page
$this->Smarty['main']->display($vw);
$this->logger->logInfo("VIEW LOAD: '".$vw."'", "FuzeWorks->Layout", __FILE__, __LINE__);
$this->logger->logInfo("VIEW LOAD: '".$vw."'", "Layout", __FILE__, __LINE__);
}catch (\SmartyException $e){
// Throw error on failure
$this->logger->logError('Could not load view '.$directory.'/'.$vw.' :: ' . $e->getMessage(), 'FuzeWorks->Layout', __FILE__, __LINE__);
$this->logger->logError('Could not load view '.$directory.'/'.$vw.' :: ' . $e->getMessage(), 'Layout', __FILE__, __LINE__);
throw new Exception\Layout('Could not load view '.$directory.'/'.$vw);
}
}
@ -165,11 +165,11 @@ class Layout extends Bus {
// Load the page
return $this->Smarty['main']->fetch('view.'.$view.'.tpl');
$this->logger->logInfo("VIEW LOAD: 'view.".$view.'.tpl'."'", "FuzeWorks->Layout", __FILE__, __LINE__);
$this->logger->logInfo("VIEW LOAD: 'view.".$view.'.tpl'."'", "Layout", __FILE__, __LINE__);
}catch (\SmartyException $e){
// Throw error on failure
$this->logger->logError('Could not load view '.$directory.'/view.'.$view.'.tpl :: ' . $e->getMessage(), 'FuzeWorks->Layout', __FILE__, __LINE__);
$this->logger->logError('Could not load view '.$directory.'/view.'.$view.'.tpl :: ' . $e->getMessage(), 'Layout', __FILE__, __LINE__);
throw new Exception\Layout('Could not load view '.$directory.'/view.'.$view.'.tpl');
}
}

View File

@ -302,8 +302,8 @@ class Logger extends Bus{
511 => 'Network Authentication Required'
);
$this->logError('HTTP-error '.$errno.' called', 'FuzeWorks->Logger');
$this->logInfo('Sending header HTTP/1.1 '.$errno.' '.$http_codes[$errno], 'FuzeWorks->Logger', __FILE__, __LINE__);
$this->logError('HTTP-error '.$errno.' called', 'Logger');
$this->logInfo('Sending header HTTP/1.1 '.$errno.' '.$http_codes[$errno], 'Logger', __FILE__, __LINE__);
header('HTTP/1.1 '.$errno.' '.$http_codes[$errno]);
}