PHP Console
if (file_exists('PhpConsole/__autoload.php')) {
require_once('PhpConsole/__autoload.php');
PhpConsole\Helper::register();
function dev($var, $tags = 'Debug', $trace = null) {
$debugData = debug_backtrace(DEBUG_BACKTRACE_PROVIDE_OBJECT);
$line = $debugData[0]['line'];
$file = str_replace('/Users/nerijus/Projects/europris_dev/', '', $debugData[0]['file']);
$code = $tags;
$text = $var;
$ignoreTraceCalls = $trace;
PhpConsole\Connector::getInstance()->getErrorsDispatcher()->dispatchError($code, $text, $file, $line, $ignoreTraceCalls);
}
} else {
function dev($var = null, $tags = null, $trace = null) {
return;
}
}