Move utils classes to Shaarli\Helper namespace and folder
This commit is contained in:
parent
977db7eabc
commit
c2cd15dac2
15 changed files with 17 additions and 12 deletions
|
@ -4,6 +4,7 @@ namespace Shaarli;
|
|||
use DateTime;
|
||||
use Exception;
|
||||
use Shaarli\Bookmark\Bookmark;
|
||||
use Shaarli\Helper\FileUtils;
|
||||
|
||||
/**
|
||||
* Class History
|
||||
|
|
|
@ -4,10 +4,10 @@ declare(strict_types=1);
|
|||
|
||||
namespace Shaarli\Front\Controller\Visitor;
|
||||
|
||||
use Shaarli\ApplicationUtils;
|
||||
use Shaarli\Container\ShaarliContainer;
|
||||
use Shaarli\Front\Exception\AlreadyInstalledException;
|
||||
use Shaarli\Front\Exception\ResourcePermissionException;
|
||||
use Shaarli\Helper\ApplicationUtils;
|
||||
use Shaarli\Languages;
|
||||
use Shaarli\Security\SessionManager;
|
||||
use Slim\Http\Request;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
<?php
|
||||
namespace Shaarli;
|
||||
namespace Shaarli\Helper;
|
||||
|
||||
use Exception;
|
||||
use Shaarli\Config\ConfigManager;
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
namespace Shaarli;
|
||||
namespace Shaarli\Helper;
|
||||
|
||||
use Shaarli\Exceptions\IOException;
|
||||
|
|
@ -8,7 +8,7 @@ use DateTime;
|
|||
use Iterator;
|
||||
use Shaarli\Bookmark\Exception\BookmarkNotFoundException;
|
||||
use Shaarli\Exceptions\IOException;
|
||||
use Shaarli\FileUtils;
|
||||
use Shaarli\Helper\FileUtils;
|
||||
use Shaarli\Render\PageCacheManager;
|
||||
|
||||
/**
|
||||
|
|
|
@ -7,7 +7,6 @@ use RainTPL;
|
|||
use ReflectionClass;
|
||||
use ReflectionException;
|
||||
use ReflectionMethod;
|
||||
use Shaarli\ApplicationUtils;
|
||||
use Shaarli\Bookmark\Bookmark;
|
||||
use Shaarli\Bookmark\BookmarkArray;
|
||||
use Shaarli\Bookmark\BookmarkFilter;
|
||||
|
@ -17,6 +16,7 @@ use Shaarli\Config\ConfigJson;
|
|||
use Shaarli\Config\ConfigManager;
|
||||
use Shaarli\Config\ConfigPhp;
|
||||
use Shaarli\Exceptions\IOException;
|
||||
use Shaarli\Helper\ApplicationUtils;
|
||||
use Shaarli\Thumbnailer;
|
||||
use Shaarli\Updater\Exception\UpdaterException;
|
||||
|
||||
|
|
|
@ -5,9 +5,9 @@ namespace Shaarli\Render;
|
|||
use Exception;
|
||||
use Psr\Log\LoggerInterface;
|
||||
use RainTPL;
|
||||
use Shaarli\ApplicationUtils;
|
||||
use Shaarli\Bookmark\BookmarkServiceInterface;
|
||||
use Shaarli\Config\ConfigManager;
|
||||
use Shaarli\Helper\ApplicationUtils;
|
||||
use Shaarli\Security\SessionManager;
|
||||
use Shaarli\Thumbnailer;
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
namespace Shaarli\Security;
|
||||
|
||||
use Psr\Log\LoggerInterface;
|
||||
use Shaarli\FileUtils;
|
||||
use Shaarli\Helper\FileUtils;
|
||||
|
||||
/**
|
||||
* Class BanManager
|
||||
|
|
|
@ -59,6 +59,7 @@
|
|||
"Shaarli\\Front\\Controller\\Admin\\": "application/front/controller/admin",
|
||||
"Shaarli\\Front\\Controller\\Visitor\\": "application/front/controller/visitor",
|
||||
"Shaarli\\Front\\Exception\\": "application/front/exceptions",
|
||||
"Shaarli\\Helper\\": "application/helper",
|
||||
"Shaarli\\Http\\": "application/http",
|
||||
"Shaarli\\Legacy\\": "application/legacy",
|
||||
"Shaarli\\Netscape\\": "application/netscape",
|
||||
|
|
2
init.php
2
init.php
|
@ -2,7 +2,7 @@
|
|||
|
||||
require_once __DIR__ . '/vendor/autoload.php';
|
||||
|
||||
use Shaarli\ApplicationUtils;
|
||||
use Shaarli\Helper\ApplicationUtils;
|
||||
use Shaarli\Security\SessionManager;
|
||||
|
||||
// Set 'UTC' as the default timezone if it is not defined in php.ini
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
<?php
|
||||
namespace Shaarli;
|
||||
namespace Shaarli\Helper;
|
||||
|
||||
use Shaarli\Config\ConfigManager;
|
||||
use Shaarli\FakeApplicationUtils;
|
||||
|
||||
require_once 'tests/utils/FakeApplicationUtils.php';
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
namespace Shaarli;
|
||||
namespace Shaarli\Helper;
|
||||
|
||||
use Exception;
|
||||
use Shaarli\Exceptions\IOException;
|
|
@ -4,7 +4,7 @@
|
|||
namespace Shaarli\Security;
|
||||
|
||||
use Psr\Log\LoggerInterface;
|
||||
use Shaarli\FileUtils;
|
||||
use Shaarli\Helper\FileUtils;
|
||||
use Shaarli\TestCase;
|
||||
|
||||
/**
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
namespace Shaarli;
|
||||
|
||||
use Shaarli\Helper\ApplicationUtils;
|
||||
|
||||
/**
|
||||
* Fake ApplicationUtils class to avoid HTTP requests
|
||||
*/
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
use Shaarli\FileUtils;
|
||||
use Shaarli\Helper\FileUtils;
|
||||
use Shaarli\History;
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue