correct use of Database use
Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cli\Action;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\SImExporter;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\Cli\ConfigServicesCmd;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cli\Action;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Cli\SwitchServerIpCmd;
|
||||
|
||||
class SwitchServerIpAction extends \Froxlor\Cli\Action
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
class CronConfig
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Dns;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use \Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use \Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\Fpm;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use \Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use \Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\Fpm;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\Fpm;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\Cron\Http\Php\PhpInterface;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\Http;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\FroxlorLogger;
|
||||
use Froxlor\Database\Database;
|
||||
|
||||
/**
|
||||
* This file is part of the Froxlor project.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\System;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
use Froxlor\FroxlorLogger;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\System;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
|
||||
/**
|
||||
* This file is part of the Froxlor project.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Cron\System;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
/**
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace Froxlor\Cron\Traffic;
|
||||
* @package Cron
|
||||
*
|
||||
*/
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
class ReportsCron extends \Froxlor\Cron\FroxlorCron
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace Froxlor\Cron\Traffic;
|
||||
* @package Cron
|
||||
*
|
||||
*/
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
class TrafficCron extends \Froxlor\Cron\FroxlorCron
|
||||
|
||||
@@ -302,7 +302,7 @@ class Database
|
||||
);
|
||||
|
||||
if ($socket != null) {
|
||||
$dbconf["dsn"]['unix_socket'] = makeCorrectFile($socket);
|
||||
$dbconf["dsn"]['unix_socket'] = \Froxlor\FileDir::makeCorrectFile($socket);
|
||||
} else {
|
||||
$dbconf["dsn"]['host'] = $host;
|
||||
$dbconf["dsn"]['port'] = $port;
|
||||
@@ -390,7 +390,7 @@ class Database
|
||||
* log to a file, so we can actually ask people for the error
|
||||
* (no one seems to find the stuff in the syslog)
|
||||
*/
|
||||
$sl_dir = makeCorrectDir(\Froxlor\Froxlor::getInstallDir() . "/logs/");
|
||||
$sl_dir = \Froxlor\FileDir::makeCorrectDir(\Froxlor\Froxlor::getInstallDir() . "/logs/");
|
||||
if (! file_exists($sl_dir)) {
|
||||
@mkdir($sl_dir, 0755);
|
||||
}
|
||||
@@ -403,7 +403,7 @@ class Database
|
||||
* log error for reporting
|
||||
*/
|
||||
$errid = substr(md5(microtime()), 5, 5);
|
||||
$err_file = makeCorrectFile($sl_dir . "/" . $errid . "_sql-error.log");
|
||||
$err_file = \Froxlor\FileDir::makeCorrectFile($sl_dir . "/" . $errid . "_sql-error.log");
|
||||
$errlog = @fopen($err_file, 'w');
|
||||
@fwrite($errlog, "|CODE " . $error->getCode() . "\n");
|
||||
@fwrite($errlog, "|MSG " . $error_message . "\n");
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Database\Manager;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
|
||||
/**
|
||||
* This file is part of the Froxlor project.
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Dns;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
class Dns
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace Froxlor\Http;
|
||||
* @since 0.9.33
|
||||
*
|
||||
*/
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\FileDir;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Http\LetsEncrypt;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
// Copyright (c) 2015, Stanislav Humplik <sh@analogic.cz>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
namespace Froxlor\Http\LetsEncrypt;
|
||||
|
||||
use Froxlor\Database;
|
||||
use Froxlor\Database\Database;
|
||||
use Froxlor\Settings;
|
||||
|
||||
// Copyright (c) 2015, Stanislav Humplik <sh@analogic.cz>
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
|
||||
namespace Froxlor;
|
||||
|
||||
use Froxlor\Database as Database;
|
||||
use Froxlor\Database\Database;
|
||||
|
||||
|
||||
/**
|
||||
* This file is part of the Froxlor project.
|
||||
|
||||
Reference in New Issue
Block a user